Save pts and date only if there is something to save

This commit is contained in:
Lonami Exo 2019-05-05 22:13:02 +02:00
parent 5ed7bf7815
commit 7d0efcf50f
2 changed files with 9 additions and 8 deletions

View File

@ -419,6 +419,7 @@ class TelegramBaseClient(abc.ABC):
self._updates_queue.clear()
pts, date = self._state_cache[None]
if pts and date:
self.session.set_update_state(0, types.updates.State(
pts=pts,
qts=0,

View File

@ -1,3 +1,3 @@
# Versions should comply with PEP440.
# This line is parsed in setup.py:
__version__ = '1.7.5'
__version__ = '1.7.6'