mirror of
https://github.com/pyrogram/pyrogram
synced 2025-09-05 08:45:13 +00:00
Make the on_disconnect callback function a coroutine
This commit is contained in:
@@ -197,7 +197,7 @@ class Session:
|
||||
|
||||
if self.client and callable(self.client.disconnect_handler):
|
||||
try:
|
||||
self.client.disconnect_handler(self.client)
|
||||
await self.client.disconnect_handler(self.client)
|
||||
except Exception as e:
|
||||
log.error(e, exc_info=True)
|
||||
|
||||
|
Reference in New Issue
Block a user