Skip to content

Commit

Permalink
🐛 Fix ignored channels verification
Browse files Browse the repository at this point in the history
  • Loading branch information
Androz2091 committed Jan 5, 2021
1 parent 0ba10aa commit befaacc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion events/message.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ module.exports = class {
});
}

if(data.guild.ignoredChannels.includes(message.channel.id) && !message.member.hasPermission("MANAGE_MESSAGES")){
if(message.guild && data.guild.ignoredChannels.includes(message.channel.id) && !message.member.hasPermission("MANAGE_MESSAGES")){
message.delete();
message.author.send(message.translate("misc:RESTRICTED_CHANNEL", {
channel: message.channel.toString()
Expand Down

0 comments on commit befaacc

Please sign in to comment.