mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
voice: null-check UDP socket
This commit is contained in:
@@ -143,7 +143,7 @@ class StreamDispatcher extends VolumeInterface {
|
||||
* @param {string} info The debug info
|
||||
*/
|
||||
this.setSpeaking(true);
|
||||
while (repeats--) {
|
||||
while (repeats-- && this.player.voiceConnection.sockets.udp) {
|
||||
this.player.voiceConnection.sockets.udp.send(packet)
|
||||
.catch(e => {
|
||||
this.setSpeaking(false);
|
||||
|
||||
Reference in New Issue
Block a user