aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/api/Commands/index.ts1
-rw-r--r--src/plugins/messageTags.ts13
2 files changed, 9 insertions, 5 deletions
diff --git a/src/api/Commands/index.ts b/src/api/Commands/index.ts
index 88139d4..3f639a1 100644
--- a/src/api/Commands/index.ts
+++ b/src/api/Commands/index.ts
@@ -111,6 +111,7 @@ function registerSubCommands(cmd: Command, plugin: string) {
...o,
type: ApplicationCommandType.CHAT_INPUT,
name: `${cmd.name} ${o.name}`,
+ id: `${o.name}-${cmd.id}`,
displayName: `${cmd.name} ${o.name}`,
subCommandPath: [{
name: o.name,
diff --git a/src/plugins/messageTags.ts b/src/plugins/messageTags.ts
index 490edc3..02d1e52 100644
--- a/src/plugins/messageTags.ts
+++ b/src/plugins/messageTags.ts
@@ -234,12 +234,15 @@ export default definePlugin({
});
break; // end 'preview'
}
- }
- return sendBotMessage(ctx.channel.id, {
- author,
- content: "Invalid sub-command"
- });
+ default: {
+ sendBotMessage(ctx.channel.id, {
+ author,
+ content: "Invalid sub-command"
+ });
+ break;
+ }
+ }
}
}
]