From 1d3dd83dc0ab62d80d40ee755bf65cacafaab94d Mon Sep 17 00:00:00 2001 From: Eduardo Braga Date: Fri, 15 Dec 2023 11:29:50 -0300 Subject: [PATCH] Add ToLowerInvairant() to HideTotals --- Mastonet/MastodonClient.Status.cs | 2 +- Mastonet/TimelineWebSocketStreaming.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Mastonet/MastodonClient.Status.cs b/Mastonet/MastodonClient.Status.cs index fca56f8..6ca560f 100644 --- a/Mastonet/MastodonClient.Status.cs +++ b/Mastonet/MastodonClient.Status.cs @@ -152,7 +152,7 @@ public Task PublishStatus(string status, Visibility? visibility = null, if (poll.HideTotals.HasValue) { - data.Add(new KeyValuePair("poll[hide_totals]", poll.HideTotals.Value.ToString())); + data.Add(new KeyValuePair("poll[hide_totals]", poll.HideTotals.Value.ToString().ToLowerInvariant())); } } diff --git a/Mastonet/TimelineWebSocketStreaming.cs b/Mastonet/TimelineWebSocketStreaming.cs index 5ff43ee..9b41630 100644 --- a/Mastonet/TimelineWebSocketStreaming.cs +++ b/Mastonet/TimelineWebSocketStreaming.cs @@ -122,7 +122,7 @@ public override void Stop() } } -[JsonSerializable(typeof(TimelineMessage))] +[JsonSerializable(typeof(TimelineMessage), GenerationMode = JsonSourceGenerationMode.Metadata)] internal partial class TimelineMessageContext : JsonSerializerContext { } \ No newline at end of file