Commit 09a4602a authored by fred's avatar fred

thumbnail: convert everything but jpeg to png

parent 0bc503d1
......@@ -17,7 +17,7 @@ def thumbnail(image, size='100x100'):
# defining the filename and the miniature filename
filehead, filetail = os.path.split(image.path)
basename, format = os.path.splitext(filetail)
if format == '.gif':
if format.lower() not in ('.jpg', '.jpeg'):
format = '.png'
miniature = basename + '__' + size + format
filename = image.path
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment