aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcookkkie <[email protected]>2017-03-13 02:25:10 +0100
committercookkkie <[email protected]>2017-03-13 02:25:10 +0100
commit2f159098b103293fa0252e54abab7e8010d7262f (patch)
tree70ff3f0ee6ceed1d73495271654e2d27ed4fd8cf
parentAdd rollback strategy to Client.join_voice_channel (diff)
downloaddiscord.py-2f159098b103293fa0252e54abab7e8010d7262f.tar.xz
discord.py-2f159098b103293fa0252e54abab7e8010d7262f.zip
Better timeout handling in join_voice_channel
-rw-r--r--discord/client.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/discord/client.py b/discord/client.py
index c9b051b1..c6d1e59d 100644
--- a/discord/client.py
+++ b/discord/client.py
@@ -3185,9 +3185,9 @@ class Client:
try:
session_id_data = yield from asyncio.wait_for(session_id_future, timeout=10.0, loop=self.loop)
data = yield from asyncio.wait_for(voice_data_future, timeout=10.0, loop=self.loop)
- except asyncio.TimeoutError:
+ except asyncio.TimeoutError as e:
yield from self.ws.voice_state(server.id, None, self_mute=True)
- return None
+ raise e
kwargs = {
'user': self.user,