fixed thumbnails by getting rid of the b"" on each thumbnail base64 encoded string

This commit is contained in:
2021-01-10 19:41:06 +11:00
parent 2d88a65ead
commit b280b21544
2 changed files with 2 additions and 1 deletions

View File

@@ -120,5 +120,6 @@ def getExif(file):
f.close()
fthumbnail = base64.b64encode(tags['JPEGThumbnail'])
fthumbnail = str(fthumbnail)[2:-2]
return fthumbnail

View File

@@ -17,7 +17,7 @@
{% endif %}
 {{obj.name}}
{% if obj.type=="Image" %}
<img width="64" height="64" src="data:image/jpg;base64,{{obj.thumbnail}}"></img>
<img width="64" height="64" src="data:image/jpeg;base64,{{obj.thumbnail}}"></img>
{% endif %}
</td></td><td>{{obj.size_MB}}</td><td>{{obj.hash}}</tr>
{% endfor %}