From 94ca0f599d01d39f06cb46f1d3fdda21b9109b53 Mon Sep 17 00:00:00 2001 From: Andreas Clausen Date: Sun, 26 Sep 2021 21:33:11 +0200 Subject: [PATCH] typings(VoiceState): allow moving members to stage channels (#6684) --- src/structures/Channel.js | 3 +-- src/structures/VoiceState.js | 4 ++-- typings/index.d.ts | 6 ++---- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/src/structures/Channel.js b/src/structures/Channel.js index 7e1c6e081..e3915eb38 100644 --- a/src/structures/Channel.js +++ b/src/structures/Channel.js @@ -116,8 +116,7 @@ class Channel extends Base { } /** - * Indicates whether this channel is voice-based - * ({@link VoiceChannel} or {@link StageChannel}). + * Indicates whether this channel is {@link BaseGuildVoiceChannel voice-based}. * @returns {boolean} */ isVoice() { diff --git a/src/structures/VoiceState.js b/src/structures/VoiceState.js index 155e0b459..f26ae6f06 100644 --- a/src/structures/VoiceState.js +++ b/src/structures/VoiceState.js @@ -149,8 +149,8 @@ class VoiceState extends Base { /** * Moves the member to a different channel, or disconnects them from the one they're in. - * @param {VoiceChannelResolvable|null} channel Channel to move the member to, or `null` if you want to disconnect - * them from voice. + * @param {GuildVoiceChannelResolvable|null} channel Channel to move the member to, or `null` if you want to + * disconnect them from voice. * @param {string} [reason] Reason for moving member to another channel or disconnecting * @returns {Promise} */ diff --git a/typings/index.d.ts b/typings/index.d.ts index 61251c5fa..135c59576 100644 --- a/typings/index.d.ts +++ b/typings/index.d.ts @@ -25,7 +25,6 @@ import { APIActionRowComponent, APIApplicationCommand, APIApplicationCommandInteractionData, - APIApplicationCommandInteractionDataOption, APIApplicationCommandOption, APIApplicationCommandPermission, APIAuditLogChange, @@ -85,7 +84,6 @@ import { RawBaseGuildData, RawChannelData, RawClientApplicationData, - RawCommandInteractionData, RawDMChannelData, RawEmojiData, RawGuildAuditLogData, @@ -407,7 +405,7 @@ export class Channel extends Base { public delete(): Promise; public fetch(force?: boolean): Promise; public isText(): this is TextBasedChannels; - public isVoice(): this is VoiceChannel | StageChannel; + public isVoice(): this is BaseGuildVoiceChannel; public isThread(): this is ThreadChannel; public toString(): ChannelMention; } @@ -2090,7 +2088,7 @@ export class VoiceState extends Base { public setDeaf(deaf?: boolean, reason?: string): Promise; public setMute(mute?: boolean, reason?: string): Promise; public disconnect(reason?: string): Promise; - public setChannel(channel: VoiceChannelResolvable | null, reason?: string): Promise; + public setChannel(channel: GuildVoiceChannelResolvable | null, reason?: string): Promise; public setRequestToSpeak(request?: boolean): Promise; public setSuppressed(suppressed?: boolean): Promise; }