From 2df51615b712c7fc5f2d8d4d4492398b6a94eb97 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Mon, 12 Aug 2013 00:12:05 -0700 Subject: [PATCH] Preventing more errors when move fails --- .../MediaFiles/EpisodeImport/ImportApprovedEpisodes.cs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/NzbDrone.Core/MediaFiles/EpisodeImport/ImportApprovedEpisodes.cs b/NzbDrone.Core/MediaFiles/EpisodeImport/ImportApprovedEpisodes.cs index 0757b1495..f0c8b05b2 100644 --- a/NzbDrone.Core/MediaFiles/EpisodeImport/ImportApprovedEpisodes.cs +++ b/NzbDrone.Core/MediaFiles/EpisodeImport/ImportApprovedEpisodes.cs @@ -68,6 +68,13 @@ public List Import(List decisions, bool newDownl if (newDownload) { episodeFile = _episodeFileUpgrader.UpgradeEpisodeFile(episodeFile, localEpisode); + + if (episodeFile == null) + { + _logger.Error("Failed to move [{0}], aborting processing", localEpisode); + continue; + } + _messageAggregator.PublishEvent(new EpisodeImportedEvent(episodeFile)); }