Gabizoc
Gabizoc
DIAdiscord.js - Imagine an app
Created by Gabizoc on 8/30/2024 in #djs-questions
BitFieldInvalid djs 14.15.3
RangeError [BitFieldInvalid]: Invalid bitfield flag or number: SEND_MESSAGES.
RangeError [BitFieldInvalid]: Invalid bitfield flag or number: SEND_MESSAGES.
ℹ️ [email protected]
if (!interaction.member.permissions.has(PermissionsBitField.Flags.SendMessages, true)) {
return interaction.followUp({ content: 'You do not have permission to send messages.' });
}

if (!interaction.guild.members.me.permissions.has(PermissionsBitField.Flags.SendMessages, true)) {
return interaction.followUp({ content: 'I do not have permission to send messages.' });
}
if (!interaction.member.permissions.has(PermissionsBitField.Flags.SendMessages, true)) {
return interaction.followUp({ content: 'You do not have permission to send messages.' });
}

if (!interaction.guild.members.me.permissions.has(PermissionsBitField.Flags.SendMessages, true)) {
return interaction.followUp({ content: 'I do not have permission to send messages.' });
}
Help me please
12 replies