mirror of
https://github.com/LonamiWebs/Telethon.git
synced 2025-08-08 21:10:29 +00:00
Fix stripped image downloads (#1165)
This commit is contained in:
@@ -344,7 +344,9 @@ class DownloadMethods(UserMethods):
|
||||
f = file
|
||||
|
||||
try:
|
||||
f.write(size.bytes)
|
||||
f.write(utils.stripped_photo_to_jpg(size.bytes)
|
||||
if isinstance(size, types.PhotoStrippedSize)
|
||||
else size.bytes)
|
||||
finally:
|
||||
if isinstance(file, str):
|
||||
f.close()
|
||||
|
Reference in New Issue
Block a user