From cb7bb1d639b1b5c2107052c03102861192d7d9fe Mon Sep 17 00:00:00 2001 From: NyuwBot Date: Wed, 3 Jan 2024 23:02:35 +0100 Subject: [PATCH] Fix StringWriter constructor in DiscordJson.cs --- DisCatSharp/Net/Serialization/DiscordJson.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DisCatSharp/Net/Serialization/DiscordJson.cs b/DisCatSharp/Net/Serialization/DiscordJson.cs index c98c6ec078..8c9028f4ec 100644 --- a/DisCatSharp/Net/Serialization/DiscordJson.cs +++ b/DisCatSharp/Net/Serialization/DiscordJson.cs @@ -79,7 +79,7 @@ public static T ToDiscordObject(this JToken token) /// The json serializer. private static string SerializeObjectInternal(object value, Type type, JsonSerializer jsonSerializer) { - var stringWriter = new StringWriter(new(256), CultureInfo.InvariantCulture); + var stringWriter = new StringWriter(new(), CultureInfo.InvariantCulture); using (var jsonTextWriter = new JsonTextWriter(stringWriter)) { jsonTextWriter.Formatting = jsonSerializer.Formatting;