Skip to content

Commit

Permalink
Fix tracker permission error
Browse files Browse the repository at this point in the history
  • Loading branch information
KwikKill committed Sep 29, 2024
1 parent c69079a commit aabe3c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion commands/lol.js
Original file line number Diff line number Diff line change
Expand Up @@ -3416,7 +3416,7 @@ async function tracker_add(client, interaction) {
return await interaction.editReply("A tracker channel already exists in this guild !");
}
// check if the bot has send message permission
if (!channel.permissionsFor(channel.guild.me).has(PermissionsBitField.Flags.SendMessages)) {
if (!channel.permissionsFor(client.user)?.has(PermissionsBitField.Flags.SendMessages)) {
return await interaction.editReply("The bot doesn't have the permission to send messages in this channel !");
}

Expand Down

0 comments on commit aabe3c8

Please sign in to comment.