From d33b152a4406bbc63c0d5294cfec2c97c38e54c8 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Fri, 7 Jun 2013 17:37:31 -0700 Subject: [PATCH] Episode.AirDate will be nulled if its before Series.FirstAired --- NzbDrone.Core/Tv/RefreshSeriesService.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/NzbDrone.Core/Tv/RefreshSeriesService.cs b/NzbDrone.Core/Tv/RefreshSeriesService.cs index 8822c04e1..b7b59b338 100644 --- a/NzbDrone.Core/Tv/RefreshSeriesService.cs +++ b/NzbDrone.Core/Tv/RefreshSeriesService.cs @@ -65,8 +65,6 @@ private void RefreshSeriesInfo(Series series) { var tuple = _seriesInfo.GetSeriesInfo(series.TvdbId); - RefreshEpisodeInfo(series, tuple.Item2); - var seriesInfo = tuple.Item1; series.Title = seriesInfo.Title; @@ -81,7 +79,7 @@ private void RefreshSeriesInfo(Series series) series.FirstAired = seriesInfo.FirstAired; _seriesService.UpdateSeries(series); - //Todo: We need to get the UtcOffset from TVRage, since its not available from trakt + RefreshEpisodeInfo(series, tuple.Item2); _messageAggregator.PublishEvent(new SeriesUpdatedEvent(series)); } @@ -147,6 +145,8 @@ private void RefreshEpisodeInfo(Series series, IEnumerable remoteEpisod episodeToUpdate.Overview = episode.Overview; episodeToUpdate.AirDate = episode.AirDate; + if (episodeToUpdate.AirDate < series.FirstAired) episodeToUpdate.AirDate = null; + successCount++; } catch (Exception e)