From c4b1c36096c93dfbb00744914f338f3fc1a6a036 Mon Sep 17 00:00:00 2001 From: "Max T. Kristiansen" Date: Mon, 9 Sep 2024 14:05:38 +0200 Subject: [PATCH] fix: check whether watchlist cache is empty before returning --- src/Provider.Plex/src/PlexWatchlistClient.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Provider.Plex/src/PlexWatchlistClient.cs b/src/Provider.Plex/src/PlexWatchlistClient.cs index 6258c44..58602a5 100644 --- a/src/Provider.Plex/src/PlexWatchlistClient.cs +++ b/src/Provider.Plex/src/PlexWatchlistClient.cs @@ -48,7 +48,10 @@ public async Task> FetchWatchlistAsync(int of CacheValue> cacheValue = await cachingProvider.GetAsync>("watchlist"); - return cacheValue.Value; + if(cacheValue.HasValue) + { + return cacheValue.Value; + } } MediaResponse watchlistContainer = await response