mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2024-11-10 19:46:36 +03:00
parent
becfe2ce7a
commit
ee0fc5cc29
|
@ -404,7 +404,9 @@ class MTProtoSender:
|
|||
|
||||
if not ok:
|
||||
self._log.error('Automatic reconnection failed %d time(s)', attempt)
|
||||
await self._disconnect(error=last_error.with_traceback(None))
|
||||
# There may be no error (e.g. automatic reconnection was turned off).
|
||||
error = last_error.with_traceback(None) if last_error else None
|
||||
await self._disconnect(error=error)
|
||||
|
||||
def _start_reconnect(self, error):
|
||||
"""Starts a reconnection in the background."""
|
||||
|
|
Loading…
Reference in New Issue
Block a user