mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-12 09:33:32 +01:00
dumb ass bug fix
This commit is contained in:
@@ -74,8 +74,10 @@ class AudioPlayer extends EventEmitter {
|
|||||||
const dispatcher = this.dispatcher;
|
const dispatcher = this.dispatcher;
|
||||||
if (transcoder) transcoder.kill();
|
if (transcoder) transcoder.kill();
|
||||||
if (dispatcher) {
|
if (dispatcher) {
|
||||||
dispatcher.removeListener('end', dispatcher.listeners('end')[0]);
|
const end = dispatcher.listeners('end')[0];
|
||||||
dispatcher.removeListener('error', dispatcher.listeners('error')[0]);
|
const error = dispatcher.listeners('error')[0];
|
||||||
|
if (end) dispatcher.removeListener('end', end);
|
||||||
|
if (error) dispatcher.removeListener('error', error);
|
||||||
dispatcher.destroy('end');
|
dispatcher.destroy('end');
|
||||||
}
|
}
|
||||||
this.currentStream = {};
|
this.currentStream = {};
|
||||||
|
|||||||
Reference in New Issue
Block a user