Merge branch 'develop' of https://github.com/pyrogram/pyrogram into develop
This commit is contained in:
commit
85e08f774d
@ -125,6 +125,7 @@ WEBDOCUMENT_URL_INVALID The web document URL is invalid
|
||||
WEBDOCUMENT_MIME_INVALID The web document mime type is invalid
|
||||
BUTTON_URL_INVALID The button url is invalid
|
||||
AUTH_BYTES_INVALID The authorization bytes are invalid
|
||||
USER_ID_INVALID The user ID is invalid
|
||||
CHANNELS_TOO_MUCH You have joined too many channels or supergroups
|
||||
ADMIN_RANK_INVALID The custom administrator title is invalid or is longer than 16 characters
|
||||
ADMIN_RANK_EMOJI_NOT_ALLOWED Emojis are not allowed in custom administrator titles
|
||||
|
|
@ -44,6 +44,9 @@ class Chat(Object):
|
||||
True, if this chat has been restricted. Supergroups, channels and bots only.
|
||||
See *restriction_reason* for details.
|
||||
|
||||
is_creator (``bool``, *optional*):
|
||||
True, if this chat owner is the current user. Supergroups, channels and groups only.
|
||||
|
||||
is_scam (``bool``, *optional*):
|
||||
True, if this chat has been flagged for scam. Supergroups, channels and bots only.
|
||||
|
||||
@ -108,6 +111,7 @@ class Chat(Object):
|
||||
type: str,
|
||||
is_verified: bool = None,
|
||||
is_restricted: bool = None,
|
||||
is_creator: bool = None,
|
||||
is_scam: bool = None,
|
||||
is_support: bool = None,
|
||||
title: str = None,
|
||||
@ -131,6 +135,7 @@ class Chat(Object):
|
||||
self.type = type
|
||||
self.is_verified = is_verified
|
||||
self.is_restricted = is_restricted
|
||||
self.is_creator = is_creator
|
||||
self.is_scam = is_scam
|
||||
self.is_support = is_support
|
||||
self.title = title
|
||||
@ -175,6 +180,7 @@ class Chat(Object):
|
||||
id=peer_id,
|
||||
type="group",
|
||||
title=chat.title,
|
||||
is_creator=getattr(channel, "creator", None),
|
||||
photo=ChatPhoto._parse(client, getattr(chat, "photo", None), peer_id, 0),
|
||||
permissions=ChatPermissions._parse(getattr(chat, "default_banned_rights", None)),
|
||||
members_count=getattr(chat, "participants_count", None),
|
||||
@ -191,6 +197,7 @@ class Chat(Object):
|
||||
type="supergroup" if channel.megagroup else "channel",
|
||||
is_verified=getattr(channel, "verified", None),
|
||||
is_restricted=getattr(channel, "restricted", None),
|
||||
is_creator=getattr(channel, "creator", None),
|
||||
is_scam=getattr(channel, "scam", None),
|
||||
title=channel.title,
|
||||
username=getattr(channel, "username", None),
|
||||
|
Loading…
Reference in New Issue
Block a user