From 683cf22ffeeadf18f8e74751a1cff94c8262f94a Mon Sep 17 00:00:00 2001 From: aljohn92 <16975578+aljohn92@users.noreply.github.com> Date: Fri, 4 Feb 2022 13:37:15 +0000 Subject: [PATCH] Assume square images as posters dimensional_asset_rename --- modules/plex.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/plex.py b/modules/plex.py index 550dfd8e..4e8cef37 100644 --- a/modules/plex.py +++ b/modules/plex.py @@ -898,7 +898,7 @@ class Plex(Library): image = Image.open(file) _w, _h = image.size image.close() - if not poster and _h > _w: + if not poster and _h >= _w: new_path = os.path.join(os.path.dirname(file), f"poster{os.path.splitext(file)[1].lower()}") os.rename(file, new_path) poster = ImageData("asset_directory", os.path.abspath(new_path), prefix=f"{item.title}'s ", is_url=False)