aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNCPlayz <[email protected]>2019-03-09 14:09:47 +0000
committerNCPlayz <[email protected]>2019-03-09 14:09:47 +0000
commit8b8e9a619efa47fa97bf6daa4f0ec849544af437 (patch)
treeab93cfeeb26fc363075d47ba27b30c47d506906b
parentAdd support for guild banners (diff)
downloaddiscord.py-8b8e9a619efa47fa97bf6daa4f0ec849544af437.tar.xz
discord.py-8b8e9a619efa47fa97bf6daa4f0ec849544af437.zip
Moved http.close to before _closed.set
-rw-r--r--discord/client.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/discord/client.py b/discord/client.py
index 26e22df9..7f9e2c30 100644
--- a/discord/client.py
+++ b/discord/client.py
@@ -440,6 +440,7 @@ class Client:
if self.is_closed():
return
+ await self.http.close()
self._closed.set()
for voice in self.voice_clients:
@@ -452,8 +453,6 @@ class Client:
if self.ws is not None and self.ws.open:
await self.ws.close()
-
- await self.http.close()
self._ready.clear()
def clear(self):