From 56e42aa4d7cfccf505d2d5bd201df60f504648d1 Mon Sep 17 00:00:00 2001 From: CKY Date: Mon, 9 Dec 2024 14:18:16 -0700 Subject: [PATCH] add command to manager (#51) * add the rest of the commands * move backup request * add command to manager --- src/interactions/commands/command-manager.ts | 2 ++ src/interactions/commands/handlers/backup-request.ts | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/interactions/commands/command-manager.ts b/src/interactions/commands/command-manager.ts index 818e306..15ff8f0 100644 --- a/src/interactions/commands/command-manager.ts +++ b/src/interactions/commands/command-manager.ts @@ -20,6 +20,7 @@ import { sendToIssuesContextMenuCommand } from './handlers/send-to-issues-contex import { randomFeaturedSlashCommand } from './handlers/random-featured-slash'; import { docsSlashCommand } from './handlers/docs/docs-slash'; import { infoSlashCommand } from './handlers/info/info-slash'; +import { backupRequestCommand } from './handlers/backup-request'; class CommandManager implements IInteractionManager { private handlers: ICommandHandler[] = []; @@ -42,6 +43,7 @@ class CommandManager implements IInteractionManager { randomFeaturedSlashCommand, docsSlashCommand, infoSlashCommand, + backupRequestCommand, ]; for (const handler of commandsToRegister) { diff --git a/src/interactions/commands/handlers/backup-request.ts b/src/interactions/commands/handlers/backup-request.ts index ae9543d..2f5e7ea 100644 --- a/src/interactions/commands/handlers/backup-request.ts +++ b/src/interactions/commands/handlers/backup-request.ts @@ -9,7 +9,7 @@ const config = new SlashCommandBuilder() .setDescription('Request a users backup') .setDefaultMemberPermissions(0); -export const saySlashCommand: ICommandHandler = { +export const backupRequestCommand: ICommandHandler = { type: CommandType.SlashCommand, config, async onTrigger(interaction) {