Editing message
I am making a bot that will update a message every hour, the code works so far but when trying to edit the message it gives the error that the command or function is not found and wfter a bit of looking i couldn#t find the problem:
Header:
Creating message:
Editing message:
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!there is a delay between the send and the edit of 2 seconds, i was also curious if that was the problem so i printed it out and the message was loaded
with this being the start of the message object:
and await just breaks it?
Resources to understand Promise:
- MDN: learn more
- Guide: learn more
- JavaScript info: learn more
but even if the message is loaded it still says that .edit is not a function, i also tried editMessage which i found somewhere else, didn't work either
yeah it was still a promise but already had the or something, it's fixed now, thanks