[lint] Remove redundant exception variables

Use bare raise statement when reraising the exception that occured, and
remove unused exception variables.  Also remove a pointless exception
handler in discord.opus.
This commit is contained in:
Hornwitser
2018-08-01 11:36:46 +02:00
committed by Rapptz
parent a71b3b5fa0
commit 4ae8e81660
5 changed files with 13 additions and 16 deletions

View File

@ -978,12 +978,12 @@ class Connectable(metaclass=abc.ABCMeta):
try:
await voice.connect(reconnect=reconnect)
except asyncio.TimeoutError as e:
except asyncio.TimeoutError:
try:
await voice.disconnect(force=True)
except Exception:
# we don't care if disconnect failed because connection failed
pass
raise e # re-raise
raise # re-raise
return voice