This commit is contained in:
Dragon Fire
2020-04-11 11:29:40 -04:00
parent dfe8c0a5e0
commit fe3a92a76e
13 changed files with 18 additions and 17 deletions
+2 -2
View File
@@ -16,8 +16,8 @@ module.exports = class UnknownCommandCommand extends Command {
}
run(msg) {
if (msg.channel.type !== 'text') return null;
if (this.client.botListGuilds.includes(msg.guild.id)) return null;
if (!msg.guild) return null;
if (msg.guild && this.client.botListGuilds.includes(msg.guild.id)) return null;
const commands = this.makeCommandArray(this.client.isOwner(msg.author), msg.channel.nsfw);
const command = msg.content.match(this.client.dispatcher._commandPatterns[this.client.commandPrefix]);
const str = command ? command[2] : msg.content.split(' ')[0];