Added types for subcommands

This commit is contained in:
2025-01-12 19:40:20 +01:00
parent 53914fa9dd
commit 560ad899f8
19 changed files with 81 additions and 42 deletions

View File

@@ -1,8 +1,9 @@
import { ActionRowBuilder, ButtonBuilder, ButtonInteraction, ButtonStyle, ChatInputCommandInteraction, ComponentType } from "discord.js"
import { ActionRowBuilder, ButtonBuilder, ButtonInteraction, ButtonStyle, ComponentType } from "discord.js"
import { devMessage, embedColor } from "~/config/options.js"
import { SubCommand } from "~/typings"
import env from "~/utils/Env.js"
export default async function prune(interaction: ChatInputCommandInteraction): Promise<void> {
const cmd: SubCommand = async (interaction) => {
await interaction.deferReply()
if (interaction.user.id !== env.prod.dev) {
@@ -118,3 +119,5 @@ export default async function prune(interaction: ChatInputCommandInteraction): P
})
})
}
export default cmd