Cache session_state and all_dcs right after connect

This commit is contained in:
Lonami Exo
2021-09-19 17:51:05 +02:00
parent 93dd2a186a
commit 545e9d69ce
5 changed files with 39 additions and 97 deletions

View File

@@ -36,7 +36,7 @@ class StateCache:
# each update in case they need to fetch missing entities.
self._logger = loggers[__name__]
if initial:
self._pts_date = initial.pts, initial.date
self._pts_date = initial.pts or None, initial.date or None
else:
self._pts_date = None, None