diff --git a/pyrogram/client.py b/pyrogram/client.py index 68afabf6..5c95296a 100644 --- a/pyrogram/client.py +++ b/pyrogram/client.py @@ -880,7 +880,7 @@ class Client(Methods, Scaffold): local_id=file_id.local_id, big=file_id.thumbnail_source == ThumbnailSource.CHAT_PHOTO_BIG ) - elif file_type in (FileType.THUMBNAIL, FileType.PHOTO): + elif file_type == FileType.PHOTO: location = raw.types.InputPhotoFileLocation( id=file_id.media_id, access_hash=file_id.access_hash, @@ -892,7 +892,7 @@ class Client(Methods, Scaffold): id=file_id.media_id, access_hash=file_id.access_hash, file_reference=file_id.file_reference, - thumb_size="" + thumb_size=file_id.thumbnail_size ) limit = 1024 * 1024 diff --git a/pyrogram/file_id.py b/pyrogram/file_id.py index 8bca0edd..c91c6431 100644 --- a/pyrogram/file_id.py +++ b/pyrogram/file_id.py @@ -166,7 +166,7 @@ class FileId: volume_id: int = None, thumbnail_source: ThumbnailSource = None, thumbnail_file_type: FileType = None, - thumbnail_size: str = None, + thumbnail_size: str = "", secret: int = None, local_id: int = None, chat_id: int = None,