awaitMessageComponent doesn't wait the set time
Hey there, I'm following the guide but I can't figure out why awaitMessageComponent doesn't wait for the set time.
Here's my code:
Here the intents in index.js
Any help would be much appreciated
9 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!
- ✅
Marked as resolved by OPLog the error you catch there
This is the error:
You indeed do not define response
you just reply without doing anything
Your response is the result of your .reply
I understand your answer, but I'm still struggling to understand how to modify the code to make it function properly.
interaction.reply returns an InteractionResponse (or message with fetchReply), on which you call .awaitMesaggeComponent.
So resolve it into a variable, response in your case
Ah ok! Something like:
instead of
Thanks 🙂
yes indeed, should work
yes, I can finally see "Success" in the console. Thank you very much 🙌