mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 00:53:31 +01:00
This commit is contained in:
@@ -301,6 +301,9 @@ class VoiceConnection extends EventEmitter {
|
||||
*/
|
||||
disconnect() {
|
||||
this.emit('closing');
|
||||
clearTimeout(this.connectTimeout);
|
||||
const conn = this.voiceManager.connections.get(this.channel.guild.id);
|
||||
if (conn === this) this.voiceManager.connections.delete(this.channel.guild.id);
|
||||
this.sendVoiceStateUpdate({
|
||||
channel_id: null,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user