diff options
author | ame <[email protected]> | 2023-10-31 17:24:25 -0500 |
---|---|---|
committer | ame <[email protected]> | 2023-10-31 17:24:25 -0500 |
commit | 53b4e132d593ac6a0d7cad6f0c988a97b68b8d2d (patch) | |
tree | 5db8aa7e1768ecec5fd1b62ea0f995a8067410ed /commands/util/emote.js | |
parent | 350d0de46b90d8a54fbf98ca500a4f88512f7a69 (diff) |
sticky slash command, extended slash commands, and other fixes
Diffstat (limited to 'commands/util/emote.js')
-rw-r--r-- | commands/util/emote.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/commands/util/emote.js b/commands/util/emote.js index b06bbef..c88f0b4 100644 --- a/commands/util/emote.js +++ b/commands/util/emote.js @@ -19,7 +19,11 @@ module.exports = { s_options:[{type:"string",name:"emote",desc:"emote to send",required:true,autocomplete:subs}, {type:"user",name:"user",desc:"user to emote to (may be optional)",required:false,autocomplete:false}], async s_main (client,Discord,interaction){ - this.exec(client,{message:interaction,emote:interaction.options.getString("emote"),mentioned:interaction.options.getUser("user")}) + let emote = interaction.options.getString("emote"); + if(Object.keys(config.avaliable_multi).includes(emote)||Object.keys(config.avaliable_solo).includes(emote)) + this.exec(client,{message:interaction,emote:emote,mentioned:interaction.options.getUser("user")}) + else + interaction.reply({content:"invalid emote!", ephemeral: true}) }, async exec(client,param){ let msg = ""; |