Mercurial > libervia-backend
diff sat/plugins/plugin_xep_0264.py @ 3273:4230aaeab9a7
plugin XEP-0231, XEP-0264: fixed some remaining encoding issue following Python 3 port
author | Goffi <goffi@goffi.org> |
---|---|
date | Mon, 18 May 2020 23:39:41 +0200 |
parents | 559a625a236b |
children | 5887fb414758 |
line wrap: on
line diff
--- a/sat/plugins/plugin_xep_0264.py Mon May 18 23:38:21 2020 +0200 +++ b/sat/plugins/plugin_xep_0264.py Mon May 18 23:39:41 2020 +0200 @@ -131,7 +131,7 @@ @param size(tuple(int)): requested size of thumbnail @return (unicode): unique id for this image/size """ - return hashlib.sha256(repr((image_uid, size))).hexdigest() + return hashlib.sha256(repr((image_uid, size)).encode()).hexdigest() def _blockingGenThumb(self, source_path, size=None, max_age=None, image_uid=None): """Generate a thumbnail for image