|
|
@ -78,7 +78,7 @@ namespace NzbDrone.Core.MetadataSource
|
|
|
|
series.Network = show.network;
|
|
|
|
series.Network = show.network;
|
|
|
|
series.AirTime = show.air_time_utc;
|
|
|
|
series.AirTime = show.air_time_utc;
|
|
|
|
series.TitleSlug = show.url.ToLower().Replace("http://trakt.tv/show/", "");
|
|
|
|
series.TitleSlug = show.url.ToLower().Replace("http://trakt.tv/show/", "");
|
|
|
|
series.Status = GetSeriesStatus(show.status);
|
|
|
|
series.Status = GetSeriesStatus(show.status, show.ended);
|
|
|
|
|
|
|
|
|
|
|
|
series.Seasons = show.seasons.Select(s => new Tv.Season
|
|
|
|
series.Seasons = show.seasons.Select(s => new Tv.Season
|
|
|
|
{
|
|
|
|
{
|
|
|
@ -114,9 +114,17 @@ namespace NzbDrone.Core.MetadataSource
|
|
|
|
return withoutExtension + "-300" + extension;
|
|
|
|
return withoutExtension + "-300" + extension;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
private static SeriesStatusType GetSeriesStatus(string status)
|
|
|
|
private static SeriesStatusType GetSeriesStatus(string status, bool? ended)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (string.IsNullOrWhiteSpace(status)) return SeriesStatusType.Continuing;
|
|
|
|
if (string.IsNullOrWhiteSpace(status))
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
if (ended.HasValue && ended.Value)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
return SeriesStatusType.Ended;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return SeriesStatusType.Continuing;
|
|
|
|
|
|
|
|
}
|
|
|
|
if (status.Equals("Ended", StringComparison.InvariantCultureIgnoreCase)) return SeriesStatusType.Ended;
|
|
|
|
if (status.Equals("Ended", StringComparison.InvariantCultureIgnoreCase)) return SeriesStatusType.Ended;
|
|
|
|
return SeriesStatusType.Continuing;
|
|
|
|
return SeriesStatusType.Continuing;
|
|
|
|
}
|
|
|
|
}
|
|
|
|