mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
additional cacher error handling + don't bother checking the requests when we don't get data back from plex
This commit is contained in:
parent
076a75b82f
commit
ba06e8630f
4 changed files with 60 additions and 24 deletions
|
@ -63,10 +63,17 @@ namespace PlexRequests.Services.Jobs
|
|||
if (settings.Enabled)
|
||||
{
|
||||
Log.Trace("Getting all tv series from Sonarr");
|
||||
var series = SonarrApi.GetSeries(settings.ApiKey, settings.FullUri);
|
||||
if (series != null)
|
||||
try
|
||||
{
|
||||
Cache.Set(CacheKeys.SonarrQueued, series, CacheKeys.TimeFrameMinutes.SchedulerCaching);
|
||||
var series = SonarrApi.GetSeries(settings.ApiKey, settings.FullUri);
|
||||
if (series != null)
|
||||
{
|
||||
Cache.Set(CacheKeys.SonarrQueued, series, CacheKeys.TimeFrameMinutes.SchedulerCaching);
|
||||
}
|
||||
}
|
||||
catch (System.Exception ex)
|
||||
{
|
||||
Log.Error(ex, "Failed caching queued items from Sonarr");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue