This commit is contained in:
parent
9b3df25de9
commit
097969e58c
|
@ -770,7 +770,7 @@ def get_thumbnail(filepath, content_type=None):
|
|||
# on broken JPEG files.
|
||||
raise OSError
|
||||
image_thumb_fp = io.BytesIO()
|
||||
image.convert('RGB').save(image_thumb_fp, 'PNG')
|
||||
image.convert('RGBA').save(image_thumb_fp, 'PNG')
|
||||
except OSError:
|
||||
# failed to create thumbnail.
|
||||
raise ThumbnailError()
|
||||
|
|
Loading…
Reference in New Issue