mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
types(Interaction): improve type guard for inGuild() (#6644)
This commit is contained in:
6
typings/index.d.ts
vendored
6
typings/index.d.ts
vendored
@@ -1025,7 +1025,11 @@ export class Interaction extends Base {
|
||||
public type: InteractionType;
|
||||
public user: User;
|
||||
public version: number;
|
||||
public inGuild(): this is this & { guildId: Snowflake; member: GuildMember | APIInteractionGuildMember };
|
||||
public inGuild(): this is this & {
|
||||
guildId: Snowflake;
|
||||
member: GuildMember | APIInteractionGuildMember;
|
||||
readonly channel: Exclude<TextBasedChannels, PartialDMChannel | DMChannel> | null;
|
||||
};
|
||||
public isButton(): this is ButtonInteraction;
|
||||
public isCommand(): this is CommandInteraction;
|
||||
public isContextMenu(): this is ContextMenuInteraction;
|
||||
|
||||
Reference in New Issue
Block a user