Why might a slash command delete itself after one use?
Hi.
I just created a command for my bot which works as expected the first time, and then just deletes itself from the registry afterwards.
I can only think the issue comes from sharding, since I recently created the sharding manager to experiment and have it ready.
Any ideas?
12 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!
- ✅
Marked as resolved by OPyou should not redeploy your commands every time your bot starts
use the REST script and deploy when you make changes
Oh.
Hm
What's the best way to handle that then?
Oh nvm, i read that wrong, my bad (unless you actually make the PUT call later on)
I do
You are right, I have a "registerCommands" method firing on every launch
Though your issue does not really appear to be related to your commands, still something to note though
Alright
Just in case, I'll fix up the method
As for whats causing your issue, i havent seen that message a lot, perhaps try asking in ddevs or wait until someone else might answer
Thank you
It is working fine now
I think it was the rest (register commands) thing.
I think Discord literally just updated to the halloween event for me, so maybe the API was bogged down or something.