Add unread messages, mentions count and unread mark to Dialog
This commit is contained in:
parent
15e3cf0fd5
commit
8b43ad8a63
@ -90,7 +90,10 @@ class GetDialogs(BaseClient):
|
||||
dialogs.append(
|
||||
pyrogram.Dialog(
|
||||
id=chat_id,
|
||||
top_message=messages.get(chat_id)
|
||||
top_message=messages.get(chat_id),
|
||||
unread_messages_count=dialog.unread_count,
|
||||
unread_mentions_count=dialog.unread_mentions_count,
|
||||
unread_mark=dialog.unread_mark
|
||||
)
|
||||
)
|
||||
|
||||
|
@ -22,7 +22,15 @@ from pyrogram.api.core import Object
|
||||
class Dialog(Object):
|
||||
ID = 0xb0700028
|
||||
|
||||
def __init__(self, id: int, top_message):
|
||||
def __init__(self,
|
||||
id: int,
|
||||
top_message,
|
||||
unread_messages_count: int,
|
||||
unread_mentions_count: int,
|
||||
unread_mark: bool):
|
||||
# TODO docstrings
|
||||
self.id = id
|
||||
self.top_message = top_message
|
||||
self.unread_messages_count = unread_messages_count
|
||||
self.unread_mentions_count = unread_mentions_count
|
||||
self.unread_mark = unread_mark
|
||||
|
Loading…
Reference in New Issue
Block a user