VNext is unable to disconnect
Created by: Speyd3r
Summary
When calling the Disconnect method on a VoiceNextConnection, basically nothing happens.
Details
When trying to disconnect a VoiceNextConnection nothing happens as the else
requirement of the RecieverLoopAsync in the WebSocketClient
https://github.com/DSharpPlus/DSharpPlus/blob/5383ebb1c3c2feac720a9c69b1c8def0337e6762/DSharpPlus/Net/WebSocket/WebSocketClient.cs#L198
https://github.com/DSharpPlus/DSharpPlus/blob/5383ebb1c3c2feac720a9c69b1c8def0337e6762/DSharpPlus/Net/WebSocket/WebSocketClient.cs#L121
Steps to reproduce
- Create a command that makes the bot join a voicechannel
- Call VoiceNextConnection#Disconnect
- Debug log still shows the connection being active
Notes
Also why is the Disconnect method not async? I see it call an async method in the Dispose method but using the GetResult() + Its in a try/catch that throws no errors