mirror of
https://github.com/pyrogram/pyrogram
synced 2025-08-28 12:57:52 +00:00
Add missing members_count attribute when parsing chats
This commit is contained in:
parent
8d700239d9
commit
74ecd2bb33
@ -170,6 +170,7 @@ class Chat(Object):
|
||||
title=chat.title,
|
||||
photo=ChatPhoto._parse(client, getattr(chat, "photo", None), peer_id),
|
||||
permissions=ChatPermissions._parse(getattr(chat, "default_banned_rights", None)),
|
||||
members_count=getattr(chat, "participants_count", None),
|
||||
client=client
|
||||
)
|
||||
|
||||
@ -188,6 +189,7 @@ class Chat(Object):
|
||||
photo=ChatPhoto._parse(client, getattr(channel, "photo", None), peer_id),
|
||||
restriction_reason=getattr(channel, "restriction_reason", None),
|
||||
permissions=ChatPermissions._parse(getattr(channel, "default_banned_rights", None)),
|
||||
members_count=getattr(channel, "participants_count", None),
|
||||
client=client
|
||||
)
|
||||
|
||||
@ -715,7 +717,6 @@ class Chat(Object):
|
||||
|
||||
return self._client.leave_chat(self.id)
|
||||
|
||||
|
||||
def export_invite_link(self):
|
||||
"""Bound method *export_invite_link* of :obj:`Chat`.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user