From 13a228d2812700ad98d0d7988721c3716034d570 Mon Sep 17 00:00:00 2001 From: Qstick Date: Sun, 19 Apr 2020 13:47:45 -0400 Subject: [PATCH] Gotify token as query parameter --- .../Notifications/Gotify/GotifyException.cs | 9 +++++++-- src/NzbDrone.Core/Notifications/Gotify/GotifyProxy.cs | 4 ++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/NzbDrone.Core/Notifications/Gotify/GotifyException.cs b/src/NzbDrone.Core/Notifications/Gotify/GotifyException.cs index 35547460a..6e11411b4 100644 --- a/src/NzbDrone.Core/Notifications/Gotify/GotifyException.cs +++ b/src/NzbDrone.Core/Notifications/Gotify/GotifyException.cs @@ -10,8 +10,13 @@ namespace NzbDrone.Core.Notifications.Gotify { } - public GotifyException(string message, Exception innerException, params object[] args) - : base(message, innerException, args) + public GotifyException(string message, params object[] args) + : base(message, args) + { + } + + public GotifyException(string message, Exception innerException) + : base(message, innerException) { } } diff --git a/src/NzbDrone.Core/Notifications/Gotify/GotifyProxy.cs b/src/NzbDrone.Core/Notifications/Gotify/GotifyProxy.cs index c61147296..6baf71932 100644 --- a/src/NzbDrone.Core/Notifications/Gotify/GotifyProxy.cs +++ b/src/NzbDrone.Core/Notifications/Gotify/GotifyProxy.cs @@ -22,13 +22,13 @@ namespace NzbDrone.Core.Notifications.Gotify try { var request = new HttpRequestBuilder(settings.Server).Post() - .AddFormParameter("token", settings.AppToken) + .AddQueryParam("token", settings.AppToken) .AddFormParameter("title", title) .AddFormParameter("message", message) .AddFormParameter("priority", settings.Priority) .Build(); - _httpClient.Post(request); + _httpClient.Execute(request); } catch (HttpException ex) {