From d27ffe7ca4da44ba48e530e3fedd91cbcade2f7f Mon Sep 17 00:00:00 2001 From: Nick Date: Tue, 14 May 2019 01:00:35 -0400 Subject: [PATCH] fix: override upload cache content-type --- server/models/assets.js | 1 + 1 file changed, 1 insertion(+) diff --git a/server/models/assets.js b/server/models/assets.js index 3ab58176..1ccecd55 100644 --- a/server/models/assets.js +++ b/server/models/assets.js @@ -111,6 +111,7 @@ module.exports = class Asset extends Model { const cachePath = path.join(process.cwd(), `data/cache/${fileHash}.dat`) return new Promise((resolve, reject) => { + res.type(path.extname(assetPath)) res.sendFile(cachePath, { dotfiles: 'deny' }, err => { if (err) { resolve(false)