mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-11 00:53:31 +01:00
fixed voice intervals not dying, bot will now fully die on close
This commit is contained in:
@@ -1139,6 +1139,9 @@ var InternalClient = (function () {
|
||||
self.state = _ConnectionState2["default"].DISCONNECTED;
|
||||
client.emit("disconnected");
|
||||
self.cleanIntervals();
|
||||
if (self.voiceConnection) {
|
||||
self.leaveVoiceChannel();
|
||||
}
|
||||
};
|
||||
|
||||
this.websocket.onerror = function (e) {
|
||||
|
||||
@@ -1030,6 +1030,9 @@ export default class InternalClient {
|
||||
self.state = ConnectionState.DISCONNECTED;
|
||||
client.emit("disconnected");
|
||||
self.cleanIntervals();
|
||||
if(self.voiceConnection){
|
||||
self.leaveVoiceChannel();
|
||||
}
|
||||
};
|
||||
|
||||
this.websocket.onerror = e => {
|
||||
|
||||
Reference in New Issue
Block a user