Skip to content

Commit

Permalink
fixed duplicated variable name
Browse files Browse the repository at this point in the history
  • Loading branch information
Dragon1320 committed Jul 31, 2018
1 parent ac0830c commit ee73c46
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bot/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ const loadCommands = async () => {
return commands;
}

let commands = loadCommands();
let loadedCommands = loadCommands();

const client = new discord.Client();
client.on("channelCreate", channel => {
Expand Down Expand Up @@ -300,7 +300,7 @@ client.on("message", async message => {
scripts = [...scripts, ...devScripts];
}

const commands = config.env === "dev" ? await loadCommands() : await commands;
const commands = config.env === "dev" ? await loadCommands() : await loadedCommands;

scripts.sort((a, b) => {

Expand Down

0 comments on commit ee73c46

Please sign in to comment.