You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 9, 2021. It is now read-only.
While da-slash does provide a delete function, it's only setup for commands it created and that still exists.
So if I delete a command's file, I can no longer call it up and delete it, I'd have to recreate the command with the same name, then delete it.
Here's a deleteCommands function that could be added to client.js, allowing you to delete all commands initialized by the bot, either globally or per guild via await slash.deleteCommands(guild_ids, del_global). guild_ids being an array of guild ids. del_global being a boolean to delete global commands or not.
While da-slash does provide a delete function, it's only setup for commands it created and that still exists.
So if I delete a command's file, I can no longer call it up and delete it, I'd have to recreate the command with the same name, then delete it.
Here's a deleteCommands function that could be added to client.js, allowing you to delete all commands initialized by the bot, either globally or per guild via
await slash.deleteCommands(guild_ids, del_global)
.guild_ids
being an array of guild ids.del_global
being a boolean to delete global commands or not.Function
Usage
Originally posted by @fasko-web in #8
The text was updated successfully, but these errors were encountered: