trevdev
trevdev
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
How can I check if a user id has permission to send messages to a channel?
Ok great thank you that makes sense. If I want to check that any given player has permission to send messages in a channel and also check if they can read the messages in a channel, what permissions do I check? Are there any caveats I should watch out for?
7 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
How can I check if a user id has permission to send messages to a channel?
channel.guild.members.cache.get(senderId)?.permissions - PermissionsBitField { bitfield: 2248473465835073n } .permissionsIn(channel) - PermissionsBitField { bitfield: 2248473465834049n }
7 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
How can I check if a user id has permission to send messages to a channel?
To my knowledge the senderId should be accurate. i logged the value and checked that it was right. also the channel is private, and the user is not in it. yet it still returns true. could there be another problem?
7 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
How can I check if a user id has permission to send messages to a channel?
senderId is the user's id.
7 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
guild.members.fetch will still fetch those who have left the server
@Qjuh can you tell me how to do that?
16 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
guild.members.fetch will still fetch those who have left the server
thanks you're a big help
16 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
guild.members.fetch will still fetch those who have left the server
thank you, i will test it out when i can. its a bit weird, because it actually seems to work at least a little bit without the guild members intent
16 replies
DIAdiscord.js - Imagine a boo! 👻
Created by trevdev on 6/22/2024 in #djs-questions
guild.members.fetch will still fetch those who have left the server
const client: ExtendedClient = new Client({ intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildMessages, GatewayIntentBits.MessageContent] })
const client: ExtendedClient = new Client({ intents: [GatewayIntentBits.Guilds, GatewayIntentBits.GuildMessages, GatewayIntentBits.MessageContent] })
hello, here are my intents, i do not know what partials means
16 replies