Fix sign in not saving self user to session file

This commit is contained in:
Lonami Exo 2018-08-02 19:40:48 +02:00
parent 7a7923b317
commit f4ea662fdd

View File

@ -122,6 +122,8 @@ class MemorySession(Session):
entities = tlo entities = tlo
else: else:
entities = [] entities = []
if hasattr(tlo, 'user'):
entities.append(tlo.user)
if hasattr(tlo, 'chats') and utils.is_list_like(tlo.chats): if hasattr(tlo, 'chats') and utils.is_list_like(tlo.chats):
entities.extend(tlo.chats) entities.extend(tlo.chats)
if hasattr(tlo, 'users') and utils.is_list_like(tlo.users): if hasattr(tlo, 'users') and utils.is_list_like(tlo.users):