From caff8ea3840338f9e28eb36229accad833263eb7 Mon Sep 17 00:00:00 2001 From: laont Date: Tue, 23 Jun 2020 18:17:24 +0300 Subject: [PATCH] Seriously last fix --- api/direct.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/direct.js b/api/direct.js index a0b40d3..1a361fb 100644 --- a/api/direct.js +++ b/api/direct.js @@ -16,7 +16,7 @@ module.exports = async (req, res) => { file.loadAttributes(async (err, file) => { file.download(options, (err, data) => { res.write(data); - res.setHeader('Conent-Type', await fileType.fromBuffer(data)); + await res.setHeader('Conent-Type', fileType.fromBuffer(data)); res.end(); }); });