Skip to content

Commit

Permalink
⬆️ better patched message.copy() method
Browse files Browse the repository at this point in the history
  • Loading branch information
tcsnmm09480 authored Nov 14, 2023
1 parent db2f11c commit 08542df
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions pyromod/listen/listen.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,19 +404,21 @@ async def copy(
"pyrogram.types.ReplyKeyboardRemove",
"pyrogram.types.ForceReply",
] = object,
**kwargs
) -> Union["pyrogram.types.Message", List["pyrogram.types.Message"]]:
if self.media:
self.text = None
return await self.oldcopy(
chat_id,
caption,
parse_mode,
caption_entities,
disable_notification,
reply_to_message_id,
schedule_date,
protect_content,
reply_markup,
chat_id=chat_id,
caption=caption,
parse_mode=parse_mode,
caption_entities=caption_entities,
disable_notification=disable_notification,
reply_to_message_id=reply_to_message_id,
schedule_date=schedule_date,
protect_content=protect_content,
reply_markup=reply_markup,
**kwargs
) # noqa


Expand Down

0 comments on commit 08542df

Please sign in to comment.