1 |
import { CommandInteraction, GuildMember, Message, User } from "discord.js"; |
import { CommandInteraction, ContextMenuInteraction, GuildMember, Message, User } from "discord.js"; |
2 |
import DiscordClient from "../client/Client"; |
import DiscordClient from "../client/Client"; |
3 |
import MessageEmbed from "../client/MessageEmbed"; |
import MessageEmbed from "../client/MessageEmbed"; |
4 |
import CommandOptions from "../types/CommandOptions"; |
import CommandOptions from "../types/CommandOptions"; |
23 |
this.config = {} as CooldownConfig; |
this.config = {} as CooldownConfig; |
24 |
} |
} |
25 |
|
|
26 |
async start(msg: Message | CommandInteraction, options: CommandOptions | InteractionOptions): Promise <boolean> { |
async start(msg: Message | CommandInteraction | ContextMenuInteraction, options: CommandOptions | InteractionOptions): Promise <boolean> { |
27 |
this.config = this.client.config.get('cooldown'); |
this.config = this.client.config.get('cooldown'); |
28 |
|
|
29 |
const { cmdName } = options; |
const { cmdName } = options; |