mirror of
https://github.com/danbulant/discord.js
synced 2026-05-27 22:11:53 +00:00
voice: more debug information, correctly listen to vws
This commit is contained in:
parent
375706beac
commit
fe51b4e89b
2 changed files with 3 additions and 2 deletions
|
|
@ -413,6 +413,8 @@ class VoiceConnection extends EventEmitter {
|
|||
ws.on('ready', this.onReady.bind(this));
|
||||
ws.on('sessionDescription', this.onSessionDescription.bind(this));
|
||||
ws.on('speaking', this.onSpeaking.bind(this));
|
||||
|
||||
this.sockets.ws.connect();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@ class VoiceWebSocket extends EventEmitter {
|
|||
*/
|
||||
this.attempts = 0;
|
||||
|
||||
this.connect();
|
||||
this.dead = false;
|
||||
this.connection.on('closing', this.shutdown.bind(this));
|
||||
}
|
||||
|
|
@ -69,7 +68,7 @@ class VoiceWebSocket extends EventEmitter {
|
|||
}
|
||||
|
||||
this.attempts++;
|
||||
this.emit('debug', `[WS] connecting with ${this.attempts} attempts`);
|
||||
this.emit('debug', `[WS] connecting, ${this.attempts} attempts, wss://${this.connection.authentication.endpoint}/`);
|
||||
|
||||
/**
|
||||
* The actual WebSocket used to connect to the Voice WebSocket Server.
|
||||
|
|
|
|||
Loading…
Reference in a new issue