collectionless exclude fix

This commit is contained in:
meisnate12 2022-01-31 22:19:49 -05:00
parent 5cd45ef6ab
commit ffa0a33724
2 changed files with 3 additions and 3 deletions

View file

@ -1 +1 @@
1.15.1-develop28
1.15.1-develop29

View file

@ -1026,8 +1026,8 @@ class CollectionBuilder:
type_override = f"{self.collection_level}s" if self.collection_level in plex.collection_level_options else None
new_dictionary = self.build_filter("plex_search", dict_data, type_override=type_override)
elif method_name == "plex_collectionless":
prefix_list = util.parse(self.Type, "exclude_prefix", dict_data, datatype="list", methods=dict_methods)
exact_list = util.parse(self.Type, "exclude", dict_data, datatype="list", methods=dict_methods)
prefix_list = util.parse(self.Type, "exclude_prefix", dict_data, datatype="list", methods=dict_methods) if "exclude_prefix" in dict_methods else []
exact_list = util.parse(self.Type, "exclude", dict_data, datatype="list", methods=dict_methods) if "exclude" in dict_methods else []
if len(prefix_list) == 0 and len(exact_list) == 0:
raise Failed(f"{self.Type} Error: you must have at least one exclusion")
exact_list.append(self.name)