mirror of
https://github.com/kirameki-cafe/Yumi.git
synced 2026-09-13 10:49:20 +00:00
Corrected types
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { MessageEmbed, User, MessagePayload, MessageOptions, GuildTextBasedChannel, TextChannel, DMChannel, PartialDMChannel, BaseGuildTextChannel, Message, ColorResolvable, Interaction, InteractionReplyOptions } from "discord.js";
|
||||
import { MessageEmbed, User, MessagePayload, MessageOptions, GuildTextBasedChannel, TextChannel, DMChannel, PartialDMChannel, BaseGuildTextChannel, Message, ColorResolvable, Interaction, InteractionReplyOptions, CommandInteraction } from "discord.js";
|
||||
import App from "..";
|
||||
import Logger from "../libs/Logger";
|
||||
import { HybridInteractionMessage } from "./DiscordModule";
|
||||
@@ -99,7 +99,7 @@ export async function sendReply(rMessage: Message, options: string | MessagePayl
|
||||
|
||||
|
||||
export async function sendMessageOrInteractionResponse(data: Message | Interaction, payload: MessageOptions | InteractionReplyOptions, replace = false) {
|
||||
const isSlashCommand = data instanceof Interaction && data.isCommand();
|
||||
const isSlashCommand = data instanceof CommandInteraction && data.isCommand();
|
||||
const isMessage = data instanceof Message;
|
||||
|
||||
if(isSlashCommand || (data instanceof Interaction && ( data.isSelectMenu() || data.isButton()))) {
|
||||
|
||||
Reference in New Issue
Block a user