🐛 Replace the guild as the manager's guild if it's undefined

This commit is contained in:
Helloyunho 2021-03-31 01:54:21 +09:00
parent b4a1ae389d
commit 9c5aea1ef8

View file

@ -30,7 +30,7 @@ export class GuildVoiceStatesManager extends BaseManager<
const guild =
raw.guild_id === undefined
? undefined
? this.guild
: await this.client.guilds.get(raw.guild_id)
return new VoiceState(this.client, raw, {
@ -57,7 +57,7 @@ export class GuildVoiceStatesManager extends BaseManager<
arr.map(async (raw) => {
const guild =
raw.guild_id === undefined
? undefined
? this.guild
: await this.client.guilds.get(raw.guild_id)
return new VoiceState(this.client, raw, {