Skip to content

Commit

Permalink
🐛 Check if help is run in a guild
Browse files Browse the repository at this point in the history
  • Loading branch information
Androz2091 committed Feb 1, 2021
1 parent 8a98960 commit 79852bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion commands/General/help.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class Help extends Command {
// if a command is provided
if(args[0]){

const isCustom = (data.guild.customCommands ? data.guild.customCommands.find((c) => c.name === args[0]) : false);
const isCustom = (message.guild && data.guild.customCommands ? data.guild.customCommands.find((c) => c.name === args[0]) : false);

// if the command doesn't exist, error message
const cmd = this.client.commands.get(args[0]) || this.client.commands.get(this.client.aliases.get(args[0]));
Expand Down

0 comments on commit 79852bc

Please sign in to comment.