From 5a3dc135016905a9729885759844af855f3f8441 Mon Sep 17 00:00:00 2001 From: Adam Chance <6444703+drakon64@users.noreply.github.com> Date: Tue, 24 Dec 2024 16:53:15 +0000 Subject: [PATCH] Disable "Convert into const" inspection --- .../Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Ktisis.Common/Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs b/Ktisis.Common/Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs index ac0de3b..6d72845 100644 --- a/Ktisis.Common/Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs +++ b/Ktisis.Common/Models/GoogleCloud/Tasks/CloudTaskHttpRequest.cs @@ -5,7 +5,11 @@ namespace Ktisis.Common.Models.GoogleCloud.Tasks; public class CloudTaskHttpRequest { public required string Url { get; init; } + + // `const` doesn't work well with (de)serialization + // ReSharper disable once ConvertToConstant.Global public readonly string HttpMethod = "POST"; + public readonly ReadOnlyDictionary Headers = new Dictionary { { "Content-Type", "application/json" },