From f946d78153b85ad726a06a1140143c8beac8766d Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Sat, 20 May 2023 16:59:06 -0700 Subject: [PATCH] Fixed: Exception when request to SABnzbd times out --- src/NzbDrone.Core/Download/Clients/Sabnzbd/SabnzbdProxy.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/NzbDrone.Core/Download/Clients/Sabnzbd/SabnzbdProxy.cs b/src/NzbDrone.Core/Download/Clients/Sabnzbd/SabnzbdProxy.cs index 7e1d3418b..6b75df782 100644 --- a/src/NzbDrone.Core/Download/Clients/Sabnzbd/SabnzbdProxy.cs +++ b/src/NzbDrone.Core/Download/Clients/Sabnzbd/SabnzbdProxy.cs @@ -1,5 +1,6 @@ -using System; +using System; using System.Net; +using System.Net.Http; using Newtonsoft.Json.Linq; using NLog; using NzbDrone.Common.Extensions; @@ -188,6 +189,10 @@ namespace NzbDrone.Core.Download.Clients.Sabnzbd { throw new DownloadClientException("Unable to connect to SABnzbd, {0}", ex, ex.Message); } + catch (HttpRequestException ex) + { + throw new DownloadClientUnavailableException("Unable to connect to SABnzbd, {0}", ex, ex.Message); + } catch (WebException ex) { if (ex.Status == WebExceptionStatus.TrustFailure)