From e8bbfa6b50a982d69c67993b0c25268db7893db5 Mon Sep 17 00:00:00 2001 From: meisnate12 Date: Thu, 5 Aug 2021 13:25:16 -0400 Subject: [PATCH] fix date error --- modules/builder.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/modules/builder.py b/modules/builder.py index 25fdcbf9..d32db6e5 100644 --- a/modules/builder.py +++ b/modules/builder.py @@ -1390,16 +1390,13 @@ class CollectionBuilder: tmdb_item = None if filter_attr in ["release", "added", "last_played", "last_episode_aired"] and modifier != ".regex": if filter_attr == "last_episode_aired": - current_data = tmdb_item.last_air_date - if current_data is None: + if tmdb_item.last_air_date is None: return False - current_data = util.validate_date(current_data, "TMDB Last Air Date") + current_data = util.validate_date(tmdb_item.last_air_date, "TMDB Last Air Date") else: current_data = getattr(current, filter_actual) if current_data is None: return False - if filter_attr == "last_episode_aired": - current_data = util.validate_date(current_data, "TMDB First Air Date") if modifier in ["", ".not"]: threshold_date = self.current_time - timedelta(days=filter_data) if (modifier == "" and (current_data is None or current_data < threshold_date)) \