From b280b21544f92d16685ddc6e7a5f374b8f7936ae Mon Sep 17 00:00:00 2001 From: Cam Date: Sun, 10 Jan 2021 19:41:06 +1100 Subject: [PATCH] fixed thumbnails by getting rid of the b"" on each thumbnail base64 encoded string --- photos.py | 1 + templates/photos.html | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/photos.py b/photos.py index 91bfb58..3996022 100644 --- a/photos.py +++ b/photos.py @@ -120,5 +120,6 @@ def getExif(file): f.close() fthumbnail = base64.b64encode(tags['JPEGThumbnail']) + fthumbnail = str(fthumbnail)[2:-2] return fthumbnail \ No newline at end of file diff --git a/templates/photos.html b/templates/photos.html index 822cef9..8ef4ad6 100644 --- a/templates/photos.html +++ b/templates/photos.html @@ -17,7 +17,7 @@ {% endif %}  {{obj.name}} {% if obj.type=="Image" %} - + {% endif %} {{obj.size_MB}}{{obj.hash}} {% endfor %}