mirror of
https://github.com/TeamPGM/pyrogram.git
synced 2024-11-16 12:51:18 +00:00
Use Photo as type for media messages
This commit is contained in:
parent
fb10b3b0e7
commit
a3761144b3
@ -329,13 +329,23 @@ def parse_messages(
|
||||
),
|
||||
width=size.w,
|
||||
height=size.h,
|
||||
file_size=file_size,
|
||||
date=photo.date
|
||||
file_size=file_size
|
||||
)
|
||||
|
||||
photo_sizes.append(photo_size)
|
||||
|
||||
photo = photo_sizes
|
||||
photo = pyrogram_types.Photo(
|
||||
id=b64encode(
|
||||
pack(
|
||||
"<qq",
|
||||
photo.id,
|
||||
photo.access_hash
|
||||
),
|
||||
b"-_"
|
||||
).decode().rstrip("="),
|
||||
date=photo.date,
|
||||
sizes=photo_sizes
|
||||
)
|
||||
elif isinstance(media, types.MessageMediaGeo):
|
||||
geo_point = media.geo
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user