From e8200c367cea8738ea738810d68bab71b18dd10a Mon Sep 17 00:00:00 2001 From: meisnate12 Date: Wed, 26 Jan 2022 09:23:19 -0500 Subject: [PATCH] item_locks when set to false will unlock --- modules/builder.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/builder.py b/modules/builder.py index bc7f8bcc..d684bd0f 100644 --- a/modules/builder.py +++ b/modules/builder.py @@ -2138,11 +2138,11 @@ class CollectionBuilder: # Locking should come before refreshing since refreshing can change metadata (i.e. if specified to both lock # background/poster and also refreshing, assume that the item background/poster should be kept) if "item_lock_background" in self.item_details: - self.library.query(item.lockArt) + self.library.query(item.lockArt if self.item_details["item_lock_background"] else item.unlockArt) if "item_lock_poster" in self.item_details: - self.library.query(item.lockPoster) + self.library.query(item.lockPoster if self.item_details["item_lock_poster"] else item.unlockPoster) if "item_lock_title" in self.item_details: - self.library.edit_query(item, {"title.locked": 1}) + self.library.edit_query(item, {"title.locked": 1 if self.item_details["item_lock_title"] else 0}) if "item_refresh" in self.item_details: delay = self.item_details["item_refresh_delay"] if "item_refresh_delay" in self.item_details else self.library.item_refresh_delay if delay > 0: