From 0ee7c492c8f010c03101f70008346b103a515960 Mon Sep 17 00:00:00 2001 From: Onur Atakan ULUSOY Date: Tue, 23 Apr 2024 21:12:50 +0300 Subject: [PATCH] Fixed get_last_dialogs for telegram --- .../communication/telegram/as_user/get_last_dialogs.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tiger/tools/communication/telegram/as_user/get_last_dialogs.py b/tiger/tools/communication/telegram/as_user/get_last_dialogs.py index fba7642..45f5dbe 100644 --- a/tiger/tools/communication/telegram/as_user/get_last_dialogs.py +++ b/tiger/tools/communication/telegram/as_user/get_last_dialogs.py @@ -35,11 +35,17 @@ async def fetch_recent_chats(limit): if number == None: number = chat.entity.id + + meta_information = None + if chat.entity.id != number: + meta_information = number + number = chat.entity.id chat_names[str(chat.id)] = { "number": number, "title": chat.name or chat.title, "type_of_entity": type_of_entity, "unread_count": chat.unread_count, + "meta_information": meta_information, } return chat_names