From d93a0c27e95fc0e66f96e47afeb7392b176709ca Mon Sep 17 00:00:00 2001 From: Qstick Date: Mon, 26 Sep 2022 14:47:29 -0500 Subject: [PATCH] Sentry logging exceptions Fixes #855 Co-Authored-By: Taloth --- src/NzbDrone.Common/Instrumentation/Sentry/SentryTarget.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/NzbDrone.Common/Instrumentation/Sentry/SentryTarget.cs b/src/NzbDrone.Common/Instrumentation/Sentry/SentryTarget.cs index 2c5e4eb71..f17eb467a 100644 --- a/src/NzbDrone.Common/Instrumentation/Sentry/SentryTarget.cs +++ b/src/NzbDrone.Common/Instrumentation/Sentry/SentryTarget.cs @@ -206,7 +206,11 @@ namespace NzbDrone.Common.Instrumentation.Sentry if (ex != null) { fingerPrint.Add(ex.GetType().FullName); - fingerPrint.Add(ex.TargetSite.ToString()); + if (ex.TargetSite != null) + { + fingerPrint.Add(ex.TargetSite.ToString()); + } + if (ex.InnerException != null) { fingerPrint.Add(ex.InnerException.GetType().FullName);