My DIscord.js bot sends two messages

Alright so yesterday I set up my bot, then I made a little project (which went to sleep after 5 minutes so I don’t think that’s the reason) and then I hit the sleep. I wake up and I check out my bot, it went to sleep after 5 minutes but I got it working and started doing some commands, but my bot was sending two commands. Well maybe the code was being weird, but it worked fine yesterday, and to debug the issue I made it log the console, it read and started doing stuff for the command once it seemed, since it wasn’t saying it received the message twice. The only reason I think this is happening is because of Glitch… When my internet (or Discord’s servers) is being a dumbo it’ll send messages twice for me.

Could someone try to help me?

Okay so I now figured out what the problem is, I renamed my project, so both versions, the renamed one and not-renamed one are running at the same time.

1 Like

Okay I fixed it by replacing my Bot’s token and updating my current one to that.

Glad you were able to work it out and get it fixed up!

1 Like