Pyrofork: Add is_join_to_send field to Chat

Signed-off-by: wulan17 <wulan17@nusantararom.org>
This commit is contained in:
wulan17 2023-12-30 18:01:00 +07:00
parent db9fef481f
commit 0117429dc9
No known key found for this signature in database
GPG key ID: 318CD6CD3A6AC0A5

View file

@ -65,6 +65,9 @@ class Chat(Object):
is_join_request (``bool``, *optional*):
True, if the admin need to approve member(s) join request.
is_join_to_send (``bool``, *optional*):
True, if only chat members allowed to send message in chat.
title (``str``, *optional*):
Title, for supergroups, channels and basic group chats.
@ -169,6 +172,7 @@ class Chat(Object):
is_forum: bool = None,
is_participants_hidden: bool = None,
is_join_request: bool = None,
is_join_to_send: bool = None,
title: str = None,
username: str = None,
first_name: str = None,
@ -206,6 +210,7 @@ class Chat(Object):
self.is_forum = is_forum
self.is_participants_hidden = is_participants_hidden
self.is_join_request = is_join_request
self.is_join_to_send = is_join_to_send
self.title = title
self.username = username
self.first_name = first_name
@ -306,6 +311,7 @@ class Chat(Object):
is_fake=getattr(channel, "fake", None),
is_forum=getattr(channel, "forum", None),
is_join_request=getattr(channel, "join_request", None),
is_join_to_send=getattr(channel, "join_to_send", None),
title=channel.title,
username=user_name,
usernames=usernames,