Button Pagination not working?
I'm doing an auto updating help command just so my server can keep up to date with what commands are available. And yes I know most of the
await aren't needed...
https://pastebin.com/mDraff2e
https://pastebin.com/Vy32rqsL
It isn't recognizing when I click the next button, and I'm not sure whyPastebin
Help.js File - Pastebin.com
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
Pastebin
Buton Pagination - Pastebin.com
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
10 Replies
explain "it isn't recognizing"
When I click the next button it just sits there and does nothing. It does actually recognize it I think because when I console.log
i.deferUpdate I get a console log. Would that help if I show that?yes
if the interaction wasn't picked up at all it would show an error to the user
if it doesn't show anything then it deferred an update
not sure what part you would want to look at https://pastebin.com/7pHwJZSn
Pastebin
i.deferupdate().then(console.log) - Pastebin.com
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
this logic is wrong

fffffff. the else if needs one more } in front of it doesn't it?
one sec
- there's no "setCustomId" in interactions, not "CustomId", it's customId
- your if logic is wrong as well
yeah
and please don't just add await to every single statement in your code
it makes the code very unreadable
learn what promises are, how they work
Resources to understand Promise:
- MDN: learn more
- Guide: learn more
- JavaScript info: learn more
The if statement fixed it 🤦♂️ I didn't even realize I had the
.setCustomId and the .CustomIds like that either...obviously lol It works now...Sometimes it's not about getting straight answers but just getting a second set of eyes on stuff