Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

FIX: If your bot unreacts to the embed #19

Open
jameslinimk opened this issue Feb 2, 2021 · 1 comment
Open

FIX: If your bot unreacts to the embed #19

jameslinimk opened this issue Feb 2, 2021 · 1 comment

Comments

@jameslinimk
Copy link

Go to index.js and remove line 13. (reaction.users.remove(msg.author);)

@psibean
Copy link

psibean commented Feb 3, 2021

Removing that line is NOT a fix. If you remove that line of code, if the user who sent a message/command to create the embed reacts it, their reaction won't be removed, therefore they will need to click multiple times to have the collect event fired for a second reaction.

The only case where that line of code is going to remove the BOTS reaction is if the message you're passing into paginationEmbed was created by the bot in the first place. This is incorrect / not the intended usage. The message you PASS into paginationEmbed should be the message sent by a member that initiated a command where your bot responded with the embed.

Either way, my PR fixes this issue by using the user parameter of the collect event instead. It also provides additional customizability.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants