From dd87f360d74f61b4532b523dc47cd734b6ffeb05 Mon Sep 17 00:00:00 2001 From: Etorix <92535668+EtorixDev@users.noreply.github.com> Date: Mon, 2 Dec 2024 18:13:27 -0800 Subject: [PATCH] CommandsAPI: Fix spread overwriting omitted subcommand options (#3057) --- src/api/Commands/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/api/Commands/index.ts b/src/api/Commands/index.ts index e5803ba0..2b7a4de6 100644 --- a/src/api/Commands/index.ts +++ b/src/api/Commands/index.ts @@ -110,6 +110,7 @@ function registerSubCommands(cmd: Command, plugin: string) { const subCmd = { ...cmd, ...o, + options: o.options !== undefined ? o.options : undefined, type: ApplicationCommandType.CHAT_INPUT, name: `${cmd.name} ${o.name}`, id: `${o.name}-${cmd.id}`,