message not being sent if missing perms
I have this code:
I'm not receiving any DMs for missing perms. Though the error shows in the console.
7 Replies
• What's your exact discord.js
npm list discord.js
and node node -v
version?
• Post the full error stack trace, not just the top part!
• Show your code!
• Explain what exactly your issue is.
• Not a discord.js issue? Check out #useful-servers.So catch the error
How? Only way I know how to catch the error is to do a try/catch. Do I put this inside one of those?
Yes, or do
Nothing logged besides the missing perms error.
Entire command: https://srcb.in/6LsyDiTtNx
Logged on every
.send
as well as added a try/catch. with logging: https://srcb.in/RsNxwu83bI
Still nothing but err DiscordAPIError[50013]: Missing Permissions
logs.
The bot has ZERO perms in this channel that I'm using for this test.
The error appears exactly why I thought, because the bought doesn't have perms in the channel I'm trying to send the report
embed to. This is expected behavior (for now).
It can take the array? how? I do it this way cause I don't know how to do it any other way.
Alright, is there a way to get (from the error message) exactly which perms are missing so I can put that in the message that is sent to the author?
Alright, ty.
Okay, now I'm having an issue with my bot sending the embed on usr.send
even when it doesn't have perms in the channel for channel.send
? https://srcb.in/n2fqlU0uKD = whole code. I just want it to send the error message in DMs otherwise people may be confused if they receive both.
Now the bot has perms in the channel but it still errors out saying it doesn't have perms. What?!Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
I did? that was the sourceb.in ...
I don't understand.
Sorry for the late replies, I didn't see these.