fix: stream dispatcher throwing key error due to missing secretKey

This commit is contained in:
Amish Shah
2018-01-13 12:47:19 +00:00
parent d96f5f246d
commit 8cab673fea
2 changed files with 3 additions and 2 deletions

View File

@@ -207,7 +207,7 @@ class StreamDispatcher extends Writable {
}
_playChunk(chunk) {
if (this.player.dispatcher !== this) return;
if (this.player.dispatcher !== this || !this.player.voiceConnection.authentication.secretKey) return;
this._setSpeaking(true);
this._sendPacket(this._createPacket(this._sdata.sequence, this._sdata.timestamp, chunk));
}