diff --git a/commands/owner/update.js b/commands/owner/update.js index 9667be34..9242e2fc 100644 --- a/commands/owner/update.js +++ b/commands/owner/update.js @@ -17,19 +17,16 @@ class EvalCommand extends Command { } async exec(message) { - async function update() { - const { stdout, stderr } = await exec('git pull'); - const Embed = this.client.util.embed() - .addField('stdout', stdout) - .addField('stderr', stderr); - message.channel.send({embed: Embed}) - .catch(() => { - message.channel.send(`stdout: ${stdout}\nstderr: ${stderr}`); - }); - console.log(`stdout: ${stdout}`); - console.error(`stderr: ${stderr}`); - } - update(); + const { stdout, stderr } = await exec('git pull'); + const Embed = this.client.util.embed() + .addField('stdout', stdout) + .addField('stderr', stderr); + message.channel.send({embed: Embed}) + .catch(() => { + message.channel.send(`stdout: ${stdout}\nstderr: ${stderr}`); + }); + console.log(`stdout: ${stdout}`); + console.error(`stderr: ${stderr}`); } }