mirror of
https://github.com/kirameki-cafe/Yumi.git
synced 2026-09-14 11:19:24 +00:00
Remove hotfix
This commit is contained in:
@@ -282,24 +282,6 @@ export class DiscordMusicPlayerInstance {
|
|||||||
}, 2000);
|
}, 2000);
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
// Hotfix for VoiceConnection stuck in signalling state around a minute
|
|
||||||
// https://github.com/discordjs/discord.js/issues/9185
|
|
||||||
this.voiceConnection.on('stateChange', (oldState: VoiceConnectionState, newState: VoiceConnectionState) => {
|
|
||||||
const oldNetworking = Reflect.get(oldState, 'networking');
|
|
||||||
const newNetworking = Reflect.get(newState, 'networking');
|
|
||||||
|
|
||||||
const networkStateChangeHandler = (
|
|
||||||
oldNetworkState: VoiceConnectionState,
|
|
||||||
newNetworkState: VoiceConnectionState
|
|
||||||
) => {
|
|
||||||
const newUdp = Reflect.get(newNetworkState, 'udp');
|
|
||||||
clearInterval(newUdp?.keepAliveInterval);
|
|
||||||
};
|
|
||||||
|
|
||||||
oldNetworking?.off('stateChange', networkStateChangeHandler);
|
|
||||||
newNetworking?.on('stateChange', networkStateChangeHandler);
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public async leaveVoiceChannel() {
|
public async leaveVoiceChannel() {
|
||||||
|
|||||||
Reference in New Issue
Block a user