Skip to content

Commit

Permalink
Clear the connected flag when potentially reconnecting the player
Browse files Browse the repository at this point in the history
  • Loading branch information
Rapptz committed Nov 22, 2020
1 parent b76b5b4 commit 52865df
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions discord/voice_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -365,6 +365,8 @@ async def connect(self, *, reconnect, timeout):
self._runner = self.loop.create_task(self.poll_voice_ws(reconnect))

async def potential_reconnect(self):
# Attempt to stop the player thread from playing early
self._connected.clear()
self.prepare_handshake()
self._potentially_reconnecting = True
try:
Expand Down

0 comments on commit 52865df

Please sign in to comment.