2 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!so i got a piece of code to fetch the first message in forum thread post
which was working before but idk exactly what got changed that its not working properly now
so the piece of code i have is
you might ask what is that comment , well idk either 😐 i didnt have that on my original code , and i only had the
but without that code between comments , my message is somehow not fetched and if i log message.size it returns 0 ( this whole code happens in event.
its all good till here and when i
i get a collection which means it got the message
and the message im testing this event on has a Mention user in it.
here is the log response
but when i try to go into an If statemnt to check if
which as i said i mention a user in my test message . it returns an error
and when i log ` it returns undefined
and my if statement error is like this
i know its a bit long
and idk if i explaint it correctly
but i cant really get to undrestand whats wrong with it ( i did research before i get to here )
thanks for the tip
earlier i tried adding a timeout before fetching the message ( it was 5 second and it was still the same )
do u have any idea how long it takes for the message to exist?
like is there an average or it depends on the amount of attachments and it varies
nah there is no such code
imma try with 20 second delay with two attachments
let me share my code before i log the message .
its the whole code since my event emitts , till i get to the part where i log it
after the log is my if statement
ok found the issue i guess
after fetching the message
i need to use this to get the first message fetched ( i also added the 20 second delay )
and when i use that constant message it works well