From 9dc46029b27049d0f5fbd89aba8e4848da22fc39 Mon Sep 17 00:00:00 2001 From: Tobiah Date: Fri, 22 Jun 2018 17:20:56 -0500 Subject: [PATCH] fix: don't show command ids from other guilds --- src/commands/Utilities/GetCommandIds.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/commands/Utilities/GetCommandIds.js b/src/commands/Utilities/GetCommandIds.js index ba73aff66..26651b0eb 100644 --- a/src/commands/Utilities/GetCommandIds.js +++ b/src/commands/Utilities/GetCommandIds.js @@ -19,7 +19,8 @@ class GetCommandIds extends Command { const fileContents = []; const commands = this.bot.commandHandler.commands .concat(this.bot.commandHandler.inlineCommands || []) - .concat(this.bot.commandHandler.customCommands || []); + .concat((this.bot.commandHandler.customCommands || []) + .filter(cc => message.guild && cc.guildId === message.guild.id)); commands .filter(command => !command.ownerOnly || (message.author.id === this.bot.owner && command.ownerOnly))