From 8de55fa203527aaa8e19a173c91f0299e33eb242 Mon Sep 17 00:00:00 2001 From: Rapptz Date: Sun, 17 Jan 2016 18:34:40 -0500 Subject: [PATCH] Update voice channel if we move to different channels. --- discord/client.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/discord/client.py b/discord/client.py index b60e38d23..1b20f5fe6 100644 --- a/discord/client.py +++ b/discord/client.py @@ -340,10 +340,14 @@ class Client: if event == 'VOICE_STATE_UPDATE': user_id = data.get('user_id') if user_id == self.user.id: + if self.is_voice_connected(): + self.voice.channel = self.get_channel(data.get('channel_id')) + self.session_id = data.get('session_id') log.debug('Session ID found: {}'.format(self.session_id)) self._session_id_found.set() + if event == 'VOICE_SERVER_UPDATE': self._voice_data_found.data = data log.debug('Voice connection data found: {}'.format(data))