fix(Client#voiceStateUpdate): newState is guaranteed

This commit is contained in:
Lewdcario
2018-10-14 13:58:34 -05:00
parent 183ba25faf
commit 16076124b2
2 changed files with 5 additions and 6 deletions

4
typings/index.d.ts vendored
View File

@@ -195,7 +195,7 @@ declare module 'discord.js' {
public on(event: 'roleUpdate', listener: (oldRole: Role, newRole: Role) => void): this;
public on(event: 'typingStart' | 'typingStop', listener: (channel: Channel, user: User) => void): this;
public on(event: 'userUpdate', listener: (oldUser: User, newUser: User) => void): this;
public on(event: 'voiceStateUpdate', listener: (oldState?: VoiceState, newState?: VoiceState) => void): this;
public on(event: 'voiceStateUpdate', listener: (oldState: VoiceState | undefined, newState: VoiceState) => void): this;
public on(event: 'webhookUpdate', listener: (channel: TextChannel) => void): this;
public on(event: string, listener: Function): this;
@@ -227,7 +227,7 @@ declare module 'discord.js' {
public once(event: 'roleUpdate', listener: (oldRole: Role, newRole: Role) => void): this;
public once(event: 'typingStart' | 'typingStop', listener: (channel: Channel, user: User) => void): this;
public once(event: 'userUpdate', listener: (oldUser: User, newUser: User) => void): this;
public once(event: 'voiceStateUpdate', listener: (oldState?: VoiceState, newState?: VoiceState) => void): this;
public once(event: 'voiceStateUpdate', listener: (oldState: VoiceState | undefined, newState: VoiceState) => void): this;
public once(event: 'webhookUpdate', listener: (channel: TextChannel) => void): this;
public once(event: string, listener: Function): this;
}