aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrea Lepori <alepori@student.ethz.ch>2020-07-22 11:52:10 +0200
committerAndrea Lepori <alepori@student.ethz.ch>2020-07-22 11:52:10 +0200
commit4880ea47681e415da64a1740a6437af73c837209 (patch)
tree3df150afc6482477db564980383330a47ceebd87
parentmore mobile optimization (diff)
downloadscout-subs-4880ea47681e415da64a1740a6437af73c837209.tar.gz
scout-subs-4880ea47681e415da64a1740a6437af73c837209.zip
use webp to save images
-rw-r--r--accounts/views.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/accounts/views.py b/accounts/views.py
index e3452d7..562524e 100644
--- a/accounts/views.py
+++ b/accounts/views.py
@@ -98,7 +98,7 @@ def personal(request):
try:
im = Image.open(myfile)
im_io = BytesIO()
- im.save(im_io, 'JPEG', quality=70)
+ im.save(im_io, 'WEBP', quality=70)
medic.vac_certificate.save(request.user.username+"_"+myfile.name, im_io)
medic.save()
except UnidentifiedImageError:
@@ -110,7 +110,7 @@ def personal(request):
try:
im = Image.open(myfile)
im_io = BytesIO()
- im.save(im_io, 'JPEG', quality=70)
+ im.save(im_io, 'WEBP', quality=70)
medic.health_care_certificate.save(request.user.username+"_"+myfile.name, im_io)
medic.save()
except UnidentifiedImageError: