diff --git a/Wabbajack.Common/Http/Client.cs b/Wabbajack.Common/Http/Client.cs index 5cddbb55..a58aed49 100644 --- a/Wabbajack.Common/Http/Client.cs +++ b/Wabbajack.Common/Http/Client.cs @@ -76,12 +76,15 @@ namespace Wabbajack.Common.Http var response = await ClientFactory.Client.SendAsync(msg, responseHeadersRead); if (response.IsSuccessStatusCode) return response; - if (errorsAsExceptions) - throw new HttpRequestException($"Http Exception {response.StatusCode} - {response.ReasonPhrase} - {msg.RequestUri}");; + if (errorsAsExceptions) + throw new HttpRequestException( + $"Http Exception {response.StatusCode} - {response.ReasonPhrase} - {msg.RequestUri}"); + ; return response; } - catch (Exception) + catch (Exception ex) { + if (ex is HttpRequestException) throw; if (retries > Consts.MaxHTTPRetries) throw; retries++;