diff options
author | Birte Kristina Friesel <derf@finalrewind.org> | 2024-05-04 21:13:27 +0200 |
---|---|---|
committer | Birte Kristina Friesel <derf@finalrewind.org> | 2024-05-04 21:13:27 +0200 |
commit | 9830bc4ef91bbb1d8ef9ce91dfcf7eb8db814c8b (patch) | |
tree | e9fdbc4d33b7688d277e187ed3c2449244271bc3 /bin | |
parent | a150b7aa4b83c1725128ecb6470b8cbf2d5e0214 (diff) |
support thumbnails for files in sub-directories
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/pyggle | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -268,8 +268,9 @@ class Thumbnail: except FileNotFoundError: pass - self.thumbname = f".thumbnails/{filename}" - if not filename.lower().endswith((".jpeg", ".jpg")): + thumb_filename = filename.replace("/", "-") + self.thumbname = f".thumbnails/{thumb_filename}" + if not self.thumbname.lower().endswith((".jpeg", ".jpg")): self.thumbname += ".jpg" im = rotate_image(im, self.exif_tag) |