Fix message.story parsing in some cases

This commit is contained in:
KurimuzonAkuma 2024-01-10 14:54:54 +03:00
parent da4b467e8f
commit fccee4d643

View File

@ -891,7 +891,7 @@ class Message(Object, Update):
else: else:
try: try:
story = await client.get_stories(utils.get_peer_id(media.peer), media.id) story = await client.get_stories(utils.get_peer_id(media.peer), media.id)
except BotMethodInvalid: except (BotMethodInvalid, ChannelPrivate):
story = await types.Story._parse(client, media, users, chats, media.peer) story = await types.Story._parse(client, media, users, chats, media.peer)
media_type = enums.MessageMediaType.STORY media_type = enums.MessageMediaType.STORY