mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
Reworked #466
This commit is contained in:
parent
4eff175424
commit
d7997d5cc0
10 changed files with 175 additions and 69 deletions
|
@ -302,7 +302,7 @@ namespace PlexRequests.Api
|
|||
}
|
||||
|
||||
|
||||
public PlexMetadata GetSeasons(string authToken, Uri plexFullHost, string ratingKey)
|
||||
public PlexSeasonMetadata GetSeasons(string authToken, Uri plexFullHost, string ratingKey)
|
||||
{
|
||||
var request = new RestRequest
|
||||
{
|
||||
|
@ -315,7 +315,7 @@ namespace PlexRequests.Api
|
|||
|
||||
try
|
||||
{
|
||||
var lib = RetryHandler.Execute(() => Api.ExecuteXml<PlexMetadata>(request, plexFullHost),
|
||||
var lib = RetryHandler.Execute(() => Api.ExecuteXml<PlexSeasonMetadata>(request, plexFullHost),
|
||||
(exception, timespan) => Log.Error(exception, "Exception when calling GetMetadata for Plex, Retrying {0}", timespan), new[] {
|
||||
TimeSpan.FromSeconds (5),
|
||||
TimeSpan.FromSeconds(10),
|
||||
|
@ -327,7 +327,7 @@ namespace PlexRequests.Api
|
|||
catch (Exception e)
|
||||
{
|
||||
Log.Error(e, "There has been a API Exception when attempting to get the Plex GetMetadata");
|
||||
return new PlexMetadata();
|
||||
return new PlexSeasonMetadata();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue