예제 #1
0
 public static Task <IList <JSONProfile> > GetProfiles(HttpClient httpClient, ILogger <SonarrClient> logger, SonarrSettings settings)
 {
     if (settings.Version == "2")
     {
         return(SonarrClientV2.GetProfiles(httpClient, logger, settings));
     }
     else
     {
         return(SonarrClientV3.GetProfiles(httpClient, logger, settings));
     }
 }
예제 #2
0
 public static Task <IList <JSONTag> > GetTags(HttpClient httpClient, ILogger <SonarrClient> logger, SonarrSettings settings)
 {
     if (settings.Version == "2")
     {
         return(Task.FromResult((IList <JSONTag>) new List <JSONTag>()));
     }
     else
     {
         return(SonarrClientV3.GetTags(httpClient, logger, settings));
     }
 }
예제 #3
0
 public static Task TestConnectionAsync(HttpClient httpClient, ILogger <SonarrClient> logger, SonarrSettings settings)
 {
     if (settings.Version == "2")
     {
         return(SonarrClientV2.TestConnectionAsync(httpClient, logger, settings));
     }
     else
     {
         return(SonarrClientV3.TestConnectionAsync(httpClient, logger, settings));
     }
 }