mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-08-05 20:50:22 +03:00
Add missing await
This commit is contained in:
parent
c0fa2ae620
commit
d20dc01afa
|
@ -2426,12 +2426,12 @@ class TelegramClient(TelegramBareClient):
|
||||||
def list_update_handlers(self):
|
def list_update_handlers(self):
|
||||||
return [callback for callback, _ in self.list_event_handlers()]
|
return [callback for callback, _ in self.list_event_handlers()]
|
||||||
|
|
||||||
def catch_up(self):
|
async def catch_up(self):
|
||||||
state = self.session.get_update_state(0)
|
state = self.session.get_update_state(0)
|
||||||
self.session.catching_up = True
|
self.session.catching_up = True
|
||||||
try:
|
try:
|
||||||
while True:
|
while True:
|
||||||
d = self(GetDifferenceRequest(state.pts, state.date, state.qts))
|
d = await self(GetDifferenceRequest(state.pts, state.date, state.qts))
|
||||||
if isinstance(d, DifferenceEmpty):
|
if isinstance(d, DifferenceEmpty):
|
||||||
state.date = d.date
|
state.date = d.date
|
||||||
state.seq = d.seq
|
state.seq = d.seq
|
||||||
|
|
Loading…
Reference in New Issue
Block a user