From dd12aa7db745dd5f867b9321336e638bc5767294 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Sun, 24 Mar 2024 15:00:12 -0400 Subject: [PATCH] guildOnly should still include owner --- framework/Client.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/framework/Client.js b/framework/Client.js index 32d89e3d..98c6eebc 100644 --- a/framework/Client.js +++ b/framework/Client.js @@ -66,6 +66,10 @@ module.exports = class CommandClient extends Client { return; } } + if (command.guildOnly && !msg.guild) { + await msg.reply(`The \`${command.name}\` command can only be used in a server channel.`); + return; + } if (!this.isOwner(msg.author)) { if (!command._enabled) { await msg.reply(`The \`${command.name}\` command is disabled.`); @@ -75,10 +79,6 @@ module.exports = class CommandClient extends Client { await msg.reply(`The \`${command.name}\` command can only be used by the bot owner.`); return; } - if (command.guildOnly && !msg.guild) { - await msg.reply(`The \`${command.name}\` command can only be used in a server channel.`); - return; - } if (command.nsfw && !msg.channel.nsfw) { await msg.reply(`The \`${command.name}\` command can only be used in NSFW channels.`); return;