New: Many UI Updates and Performance Tweaks

This commit is contained in:
Qstick
2019-04-12 23:25:58 -04:00
parent b24a40797f
commit 6275737ced
389 changed files with 7961 additions and 5635 deletions

View File

@@ -1,3 +1,4 @@
using NzbDrone.Common.Extensions;
using NzbDrone.Common.Http;
using NzbDrone.Common.Serializer;
using NzbDrone.Core.Rest;
@@ -32,13 +33,10 @@ namespace NzbDrone.Core.Notifications.Webhook
request.Headers.ContentType = "application/json";
request.SetContent(body.ToJson());
if (!String.IsNullOrEmpty(settings.Username) || !String.IsNullOrEmpty(settings.Password))
if (settings.Username.IsNotNullOrWhiteSpace() || settings.Password.IsNotNullOrWhiteSpace())
{
var authInfo = settings.Username + ":" + settings.Password;
authInfo = Convert.ToBase64String(Encoding.GetEncoding("ISO-8859-1").GetBytes(authInfo));
request.Headers.Set("Authorization", "Basic " + authInfo);
request.AddBasicAuthentication(settings.Username, settings.Password);
}
_httpClient.Execute(request);
}
catch (RestException ex)