From c7d30ae703cd755860ffbdf88eee7e5637cdf61f Mon Sep 17 00:00:00 2001 From: Taloth Saldono Date: Sat, 29 Jul 2017 11:35:39 +0200 Subject: [PATCH] Include releaseTitle in InvalidSceneMappingException. --- .../Scene/InvalidSceneMappingException.cs | 8 ++++---- .../DataAugmentation/Scene/SceneMappingService.cs | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/NzbDrone.Core/DataAugmentation/Scene/InvalidSceneMappingException.cs b/src/NzbDrone.Core/DataAugmentation/Scene/InvalidSceneMappingException.cs index ec9f56c6b..9e291eeb6 100644 --- a/src/NzbDrone.Core/DataAugmentation/Scene/InvalidSceneMappingException.cs +++ b/src/NzbDrone.Core/DataAugmentation/Scene/InvalidSceneMappingException.cs @@ -8,15 +8,15 @@ namespace NzbDrone.Core.DataAugmentation.Scene { public class InvalidSceneMappingException : NzbDroneException { - public InvalidSceneMappingException(IEnumerable mappings) - : base(FormatMessage(mappings)) + public InvalidSceneMappingException(IEnumerable mappings, string releaseTitle) + : base(FormatMessage(mappings, releaseTitle)) { } - private static string FormatMessage(IEnumerable mappings) + private static string FormatMessage(IEnumerable mappings, string releaseTitle) { - return string.Format("Scene Mappings contains a conflict for tvdbids {0}. Please notify Sonarr developers.", string.Join(",", mappings.Select(v => v.TvdbId.ToString()))); + return string.Format("Scene Mappings contains a conflict for tvdbids {0}. Please notify Sonarr developers. ({1})", string.Join(",", mappings.Select(v => v.TvdbId.ToString())), releaseTitle); } } } diff --git a/src/NzbDrone.Core/DataAugmentation/Scene/SceneMappingService.cs b/src/NzbDrone.Core/DataAugmentation/Scene/SceneMappingService.cs index ad89de89f..f1adebf26 100644 --- a/src/NzbDrone.Core/DataAugmentation/Scene/SceneMappingService.cs +++ b/src/NzbDrone.Core/DataAugmentation/Scene/SceneMappingService.cs @@ -109,7 +109,7 @@ namespace NzbDrone.Core.DataAugmentation.Scene return distinctMappings.FirstOrDefault(); } - throw new InvalidSceneMappingException(mappings); + throw new InvalidSceneMappingException(mappings, releaseTitle); } public int? GetSceneSeasonNumber(string seriesTitle, string releaseTitle)