Skip to content

Commit

Permalink
Pyrofork: Fix MessageReplyStoryHeader parser
Browse files Browse the repository at this point in the history
Signed-off-by: wulan17 <[email protected]>
  • Loading branch information
wulan17 committed Jan 1, 2024
1 parent 5f3c4ca commit 243bc6c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions pyrogram/types/messages_and_media/message.py
Original file line number Diff line number Diff line change
Expand Up @@ -1073,11 +1073,11 @@ async def _parse(
)

if message.reply_to:
parsed_message.quote_text = message.reply_to.quote_text
if len(message.reply_to.quote_entities) > 0:
quote_entities = [types.MessageEntity._parse(client, entity, users) for entity in message.reply_to.quote_entities]
parsed_message.quote_entities = types.List(filter(lambda x: x is not None, quote_entities))
if isinstance(message.reply_to, raw.types.MessageReplyHeader):
parsed_message.quote_text = message.reply_to.quote_text
if len(message.reply_to.quote_entities) > 0:
quote_entities = [types.MessageEntity._parse(client, entity, users) for entity in message.reply_to.quote_entities]
parsed_message.quote_entities = types.List(filter(lambda x: x is not None, quote_entities))
if message.reply_to.forum_topic:
if message.reply_to.reply_to_top_id:
thread_id = message.reply_to.reply_to_top_id
Expand Down

0 comments on commit 243bc6c

Please sign in to comment.