From df406a46395be0c16c430611bcf396e78cfbfbc3 Mon Sep 17 00:00:00 2001 From: 4Parker02991 <4parker02991@noreply.localhost> Date: Sat, 27 Jan 2024 10:48:04 -0500 Subject: [PATCH] Update commands/evaljsvm2.js --- commands/evaljsvm2.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/commands/evaljsvm2.js b/commands/evaljsvm2.js index cb9b401..396e066 100644 --- a/commands/evaljsvm2.js +++ b/commands/evaljsvm2.js @@ -33,12 +33,12 @@ trustLevel: 1, case 'run': try { const output = vm.run(args.slice(2).join(' ')) -if (bot.options.Core.CorelessMode){ +if (!bot.options.Core.enabled){ bot.chat(ChatMessage.fromNotch([cmd, { text: util.inspect(output, { stylize }) }]).toMotd().replaceAll('§', '&')) }else source.sendFeedback([cmd, { text: util.inspect(output, { stylize }) }]) } catch (e) { - if(!bot.options.Core.CorelessMode){ + if(!bot.options.Core.enabled){ bot.chat(ChatMessage.fromNotch([cmd, { text: e.stack, color: 'black' }]).toMotd().replaceAll('§', '&')) }else{ source.sendFeedback([cmd, { text: e.stack, color: 'black' }]) @@ -47,14 +47,14 @@ if (bot.options.Core.CorelessMode){ break case 'reset': vm = new VM(options) -if(bot.options.Core.CorelessMode){ +if(!bot.options.Core.enabled){ bot.chat(ChatMessage.fromNotch([cmd, { text: 'Successfully reset the eval context', color: 'green' }]).toMotd().replaceAll('§', '&')) }else{ source.sendFeedback([cmd, { text: 'Successfully reset the eval context', color: 'green' }]) } break default: - if(bot.options.Core.CorelessMode){ + if(!bot.options.Core.enabled){ bot.chat(ChatMessage.fromNotch([cmd, { text: 'Invalid option!', color: 'dark_red' }]).toMotd().replaceAll('§', '&')) }else{ source.sendFeedback([cmd, { text: 'Invalid option!', color: 'dark_red' }])