Attempt to Fix Bug

This commit is contained in:
Daniel Odendahl Jr
2017-08-21 21:29:48 +00:00
parent 8d6e964698
commit 91c4c30aee
7 changed files with 7 additions and 9 deletions
+1 -1
View File
@@ -59,7 +59,7 @@ module.exports = class HackbanCommand extends Command {
return msg.say(`Could not ban the user: \`${err.message}\``);
}
await msg.say(`Successfully banned ${user.tag}.`);
if (!modlogs) {
if (!modlogs || !modlogs.permissionsFor(this.client.user).has('SEND_MESSAGES')) {
return msg.say('Could not log the ban to the mod logs.');
} else if (modlogs.permissionsFor(this.client.user).has('EMBED_LINKS')) {
const embed = new MessageEmbed()