From 563343d3ffff9f3707a418b30ea9910655d0e401 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sun, 23 May 2021 07:17:20 -0400 Subject: [PATCH] Only allow js in beautify --- commands/code/beautify.js | 1 + 1 file changed, 1 insertion(+) diff --git a/commands/code/beautify.js b/commands/code/beautify.js index dc6d7432..9dd4dbe9 100644 --- a/commands/code/beautify.js +++ b/commands/code/beautify.js @@ -21,6 +21,7 @@ module.exports = class BeautifyCommand extends Command { } run(msg, { code }) { + if (code.lang && code.lang !== 'js') return msg.reply('I can only beautify JavaScript.'); return msg.reply(`\`\`\`${code.lang || 'js'}\n${beautify(code.code)}\n\`\`\``); } };