mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-02-03 05:04:33 +03:00
Don't hold ._updates_lock while calling .handlers
This commit is contained in:
parent
143e046cf5
commit
0235fce99c
|
@ -77,9 +77,10 @@ class UpdateState:
|
|||
self._state = update
|
||||
elif not hasattr(update, 'pts') or update.pts > self._state.pts:
|
||||
self._state.pts = getattr(update, 'pts', self._state.pts)
|
||||
for handler in self.handlers:
|
||||
handler(update)
|
||||
|
||||
if self._polling:
|
||||
self._updates.append(update)
|
||||
self._updates_available.set()
|
||||
|
||||
for handler in self.handlers:
|
||||
handler(update)
|
||||
|
|
Loading…
Reference in New Issue
Block a user