diff options
Diffstat (limited to 'commands/delete.js')
-rw-r--r-- | commands/delete.js | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/commands/delete.js b/commands/delete.js new file mode 100644 index 0000000..60c541f --- /dev/null +++ b/commands/delete.js @@ -0,0 +1,17 @@ +const { SlashCommandBuilder } = require('discord.js'); + +module.exports = { + data: new SlashCommandBuilder() + .setName('remove') + .setDescription('Remove a Command') + .addStringOption(option => + option.setName('command') + .setDescription('Name of the command to remove') + .setRequired(true) + .setChoices(...global.data.getList()) + ), + async execute(interaction) { + global.data.remove(interaction.options.getString('command')) + await interaction.reply('Removed `'+interaction.options.getString('command')+'`.'); + }, +};
\ No newline at end of file |