From 96ea7baffe6dc71222d5e11cf688f70bad956e7e Mon Sep 17 00:00:00 2001 From: meisnate12 Date: Wed, 7 Apr 2021 22:15:52 -0400 Subject: [PATCH] fix for #186 plex_search will Fail if theres no valid search --- modules/builder.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/builder.py b/modules/builder.py index ddcead49..836d96e3 100644 --- a/modules/builder.py +++ b/modules/builder.py @@ -717,7 +717,10 @@ class CollectionBuilder: raise Failed(f"Collection Error: modifier: {modifier} not supported with the {search} plex search attribute") else: raise Failed(f"Collection Error: {search_final} plex search attribute not supported") - self.methods.append((method_name, [searches])) + if len(searches) > 0: + self.methods.append((method_name, [searches])) + else: + raise Failed("Collection Error: no valid plex search attributes") elif method_name == "tmdb_discover": new_dictionary = {"limit": 100} for discover_name, discover_data in method_data.items():