From 438673df66a8040595fb2e2f41c6a54a0dbe4b58 Mon Sep 17 00:00:00 2001 From: blacktwin Date: Sat, 7 Sep 2019 23:31:21 -0400 Subject: [PATCH] #184 fix for sort_by_date returning None --- fun/playlist_manager.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fun/playlist_manager.py b/fun/playlist_manager.py index 9fd7214..a6a1bb9 100644 --- a/fun/playlist_manager.py +++ b/fun/playlist_manager.py @@ -459,8 +459,9 @@ def get_content(libraries, jbop, filters=None, search=None, limit=None): for child in plex_library.all(): for episode in child.episodes(): if jbop.startswith("history"): - item_date = sort_by_dates(episode, jbop) - child_lst += item_date + if sort_by_dates(episode, jbop): + item_date = sort_by_dates(episode, jbop) + child_lst += item_date else: child_lst += [episode.ratingKey] else: