3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-14 13:55:03 +00:00

Used guildPluginSlashCommand instead of raw blueprints

This commit is contained in:
Lily Bergonzat 2024-03-05 05:05:03 +01:00
parent 7eff7bcaa6
commit cbec6101e0
27 changed files with 168 additions and 121 deletions

View file

@ -1,7 +1,8 @@
import { slashOptions } from "knub";
import { actualHideCaseCmd } from "../../functions/actualCommands/actualHideCaseCmd";
import { modActionsSlashCmd } from "../../types";
export const HideCaseSlashCmd = {
export const HideCaseSlashCmd = modActionsSlashCmd({
name: "hidecase",
configPermission: "can_hidecase",
description: "Hide the specified case so it doesn't appear in !cases or !info",
@ -13,6 +14,6 @@ export const HideCaseSlashCmd = {
async run({ interaction, options, pluginData }) {
await interaction.deferReply({ ephemeral: true });
actualHideCaseCmd(pluginData, interaction, options["case-number"].split(/[\s,]+/).map(Number));
actualHideCaseCmd(pluginData, interaction, options["case-number"].split(/\D+/).map(Number));
},
};
});