mirror of
https://github.com/Mayuri-Chan/pyrofork.git
synced 2025-12-29 12:04:51 +00:00
pyrofork: Add missing allow_paid_broadcast parameter to copy_message and forward_messages method
Signed-off-by: wulan17 <wulan17@nusantararom.org>
This commit is contained in:
parent
5dda91d3b0
commit
efce392266
2 changed files with 10 additions and 0 deletions
|
|
@ -42,6 +42,7 @@ class CopyMessage:
|
|||
reply_to_message_id: int = None,
|
||||
schedule_date: datetime = None,
|
||||
protect_content: bool = None,
|
||||
allow_paid_broadcast: bool = None,
|
||||
invert_media: bool = False,
|
||||
reply_markup: Union[
|
||||
"types.InlineKeyboardMarkup",
|
||||
|
|
@ -105,6 +106,9 @@ class CopyMessage:
|
|||
protect_content (``bool``, *optional*):
|
||||
Protects the contents of the sent message from forwarding and saving.
|
||||
|
||||
allow_paid_broadcast (``bool``, *optional*):
|
||||
Pass True to allow the message to ignore regular broadcast limits for a small fee; for bots only.
|
||||
|
||||
invert_media (``bool``, *optional*):
|
||||
Inverts the position of the media and caption.
|
||||
|
||||
|
|
@ -135,6 +139,7 @@ class CopyMessage:
|
|||
reply_to_message_id=reply_to_message_id,
|
||||
schedule_date=schedule_date,
|
||||
protect_content=protect_content,
|
||||
allow_paid_broadcast=allow_paid_broadcast,
|
||||
invert_media=invert_media,
|
||||
reply_markup=reply_markup
|
||||
)
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ class ForwardMessages:
|
|||
disable_notification: bool = None,
|
||||
schedule_date: datetime = None,
|
||||
protect_content: bool = None,
|
||||
allow_paid_broadcast: bool = None,
|
||||
drop_author: bool = None
|
||||
) -> Union["types.Message", List["types.Message"]]:
|
||||
"""Forward messages of any kind.
|
||||
|
|
@ -71,6 +72,9 @@ class ForwardMessages:
|
|||
protect_content (``bool``, *optional*):
|
||||
Protects the contents of the sent message from forwarding and saving.
|
||||
|
||||
allow_paid_broadcast (``bool``, *optional*):
|
||||
Pass True to allow the message to ignore regular broadcast limits for a small fee; for bots only.
|
||||
|
||||
drop_author (``bool``, *optional*):
|
||||
Forwards messages without quoting the original author
|
||||
|
||||
|
|
@ -101,6 +105,7 @@ class ForwardMessages:
|
|||
random_id=[self.rnd_id() for _ in message_ids],
|
||||
schedule_date=utils.datetime_to_timestamp(schedule_date),
|
||||
noforwards=protect_content,
|
||||
allow_paid_floodskip=allow_paid_broadcast,
|
||||
drop_author=drop_author
|
||||
)
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue