diff --git a/src/client/Client.ts b/src/client/Client.ts index ede0dfc..5043d0d 100644 --- a/src/client/Client.ts +++ b/src/client/Client.ts @@ -179,9 +179,7 @@ class Mov extends CommandClient { } const userPref = await this.database.user.get(msg.author.id); - const e = await this.checkPrefixMod(msg) - console.log(e) - if ((msg.prefix as any) = e) { + if ((msg.prefix as any) = await this.checkPrefixMod(msg)) { this.commandHandler(msg, userPref || undefined); } } diff --git a/src/commands/level/migrate.ts b/src/commands/level/migrate.ts index a6df58c..2861dc6 100644 --- a/src/commands/level/migrate.ts +++ b/src/commands/level/migrate.ts @@ -11,7 +11,7 @@ async function generator(msg: Message, args: string[]) { if (!userId || !xp || !totalXP || !level) { client.createMessage( msg.channel.id, - `Usage: \`${msg.prefix}${msg.command} \``, + `Usage: \`${msg.prefix}migrate \``, ); return; } diff --git a/src/commands/level/nukeleaderboard.ts b/src/commands/level/nukeleaderboard.ts index 764cc26..99334af 100644 --- a/src/commands/level/nukeleaderboard.ts +++ b/src/commands/level/nukeleaderboard.ts @@ -14,13 +14,13 @@ function generator(msg: Message, _args: string[]) { }); client.createMessage( msg.channel.id, - `Are you sure to nuke the leaderboard? **THIS ACTION CANNOT BE REVERTED**\nPlease type \`${id}\` to confirm!`, + `Are you sure you want to nuke the leaderboard? **THIS ACTION CANNOT BE REVERTED**\nPlease type \`${id}\` to confirm!`, ); collector.on("end", (c) => { const msg = c[0]; if (msg.content === id) { client.database.level.deleteAll(); - client.createMessage(msg.channel.id, "NUKED!"); + client.createMessage(msg.channel.id, "**NUKED!** If you actually changed your mind, there's no way to restore it. Sorry about that."); } else { client.createMessage(msg.channel.id, "Ok, cancelled."); } diff --git a/src/utils/debug.ts b/src/utils/debug.ts index 09ed249..72179dc 100644 --- a/src/utils/debug.ts +++ b/src/utils/debug.ts @@ -1,7 +1,7 @@ import { dateToString } from "./dateToString"; export function debug(...info: any[]) { - if (process.env.DEBUG) { + if (Number(process.env.DEBUG)) { const date = new Date(); console.debug( `[DEBUG - ${dateToString(date, {