mirror of
https://github.com/danbulant/discord.js
synced 2026-05-24 20:42:27 +00:00
some voice fixes
This commit is contained in:
parent
f192d16b5b
commit
b7204f33b9
2 changed files with 5 additions and 1 deletions
File diff suppressed because one or more lines are too long
|
|
@ -38,6 +38,9 @@ class VoiceConnectionPlayer extends EventEmitter {
|
|||
|
||||
_shutdown() {
|
||||
this.speaking = false;
|
||||
if (this.dispatcher) {
|
||||
this.dispatcher._triggerTerminalState('end', 'ended by parent player shutdown');
|
||||
}
|
||||
for (const stream of this.processMap.keys()) this.killStream(stream);
|
||||
}
|
||||
|
||||
|
|
@ -46,6 +49,7 @@ class VoiceConnectionPlayer extends EventEmitter {
|
|||
this._streamingData = this.dispatcher.streamingData;
|
||||
this.emit('debug', 'cleaning up streams after end/error');
|
||||
if (streams) {
|
||||
this.processMap.delete(stream);
|
||||
if (streams.inputStream && streams.pcmConverter) {
|
||||
try {
|
||||
if (streams.inputStream.unpipe) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue