Missing Access Error
I get this error:
pretty sure it's from this code:
but im not sure , because it doesnt print line numbers and i have no idea why it doesn't just catch it
my code works fine, but then the whole app just crashes with this error
4 Replies
- What's your exact discord.js
npm list discord.js
and node node -v
version?
- Not a discord.js issue? Check out #other-js-ts.
- Consider reading #how-to-get-help to improve your question!
- Explain what exactly your issue is.
- Post the full error stack trace, not just the top part!
- Show your code!
- Issue solved? Press the button!"discord.js": "^13.15.0",
node -v
v16.17.0
I can confirm commenting out that code makes the error never appear
even wrapping it in trycatch does not stop the error:
<Promise>.catch()
takes a callback function
currently you're just calling console.log
and passing what it returns (undefined
)
furthermore try/catch only catches errors that are synchronously thrown within the try block
you'd need to await the promise for try/catch to handle it
as for the actual error, it means exactly what it says
your bot doesn't have access to that channel