mirror of
https://github.com/danbulant/discord.js
synced 2026-06-07 08:41:29 +00:00
voice: fix bug where no audio could be heard if voice region changed
This commit is contained in:
parent
384fdf8f17
commit
fa886eaae9
1 changed files with 2 additions and 2 deletions
|
|
@ -286,7 +286,7 @@ class VoiceConnection extends EventEmitter {
|
||||||
reconnect(token, endpoint) {
|
reconnect(token, endpoint) {
|
||||||
this.authentication.token = token;
|
this.authentication.token = token;
|
||||||
this.authentication.endpoint = endpoint;
|
this.authentication.endpoint = endpoint;
|
||||||
|
this.speaking = false;
|
||||||
this.status = VoiceStatus.RECONNECTING;
|
this.status = VoiceStatus.RECONNECTING;
|
||||||
/**
|
/**
|
||||||
* Emitted when the voice connection is reconnecting (typically after a region change).
|
* Emitted when the voice connection is reconnecting (typically after a region change).
|
||||||
|
|
@ -331,7 +331,7 @@ class VoiceConnection extends EventEmitter {
|
||||||
*/
|
*/
|
||||||
cleanup() {
|
cleanup() {
|
||||||
this.player.destroy();
|
this.player.destroy();
|
||||||
|
this.speaking = false;
|
||||||
const { ws, udp } = this.sockets;
|
const { ws, udp } = this.sockets;
|
||||||
|
|
||||||
if (ws) {
|
if (ws) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue