From a169ebff2adda5c8585c6aae6249b1c1f7c12264 Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Fri, 5 Apr 2024 23:11:03 -0700 Subject: [PATCH] Fixed: Sending ntfy.sh notifications with unicode characters Closes #6679 --- src/NzbDrone.Core/Notifications/Ntfy/NtfyProxy.cs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/NzbDrone.Core/Notifications/Ntfy/NtfyProxy.cs b/src/NzbDrone.Core/Notifications/Ntfy/NtfyProxy.cs index 4198ce38c..d35810db8 100644 --- a/src/NzbDrone.Core/Notifications/Ntfy/NtfyProxy.cs +++ b/src/NzbDrone.Core/Notifications/Ntfy/NtfyProxy.cs @@ -2,7 +2,6 @@ using System; using System.Collections.Generic; using System.Linq; using System.Net; - using FluentValidation.Results; using NLog; using NzbDrone.Common.Extensions; @@ -115,18 +114,18 @@ namespace NzbDrone.Core.Notifications.Ntfy { try { - requestBuilder.Headers.Add("X-Title", title); - requestBuilder.Headers.Add("X-Message", message); - requestBuilder.Headers.Add("X-Priority", settings.Priority.ToString()); + requestBuilder.AddQueryParam("title", title); + requestBuilder.AddQueryParam("message", message); + requestBuilder.AddQueryParam("priority", settings.Priority.ToString()); if (settings.Tags.Any()) { - requestBuilder.Headers.Add("X-Tags", settings.Tags.Join(",")); + requestBuilder.AddQueryParam("tags", settings.Tags.Join(",")); } if (!settings.ClickUrl.IsNullOrWhiteSpace()) { - requestBuilder.Headers.Add("X-Click", settings.ClickUrl); + requestBuilder.AddQueryParam("click", settings.ClickUrl); } if (!settings.AccessToken.IsNullOrWhiteSpace())