From 3b3ebc410b064d384cb97c7940b4d891c9e6f5fe Mon Sep 17 00:00:00 2001 From: loicbersier Date: Wed, 26 Feb 2020 21:07:43 +0100 Subject: [PATCH] 3gp as mp4 --- commands/utility/download.js | 1 + 1 file changed, 1 insertion(+) diff --git a/commands/utility/download.js b/commands/utility/download.js index 1fe1e380..92f872b8 100644 --- a/commands/utility/download.js +++ b/commands/utility/download.js @@ -77,6 +77,7 @@ class DownloadCommand extends Command { if (fs.existsSync(`${os.tmpdir()}/${fileName}`)) { ext = await filetype.fromFile(`${os.tmpdir()}/${fileName}`); ext = ext.ext; // This look stupid but hey, it work + if (ext == '3gp') ext = 'mp4'; // Change 3gp file extension to mp4 so discord show the video ( and to stop people from complaining ) fs.renameSync(`${os.tmpdir()}/${fileName}`, `${os.tmpdir()}/${fileName}.${ext}`); }