1
0
mirror of https://github.com/ppy/osu.git synced 2026-05-20 01:19:52 +08:00

Merge pull request #16321 from peppy/fix-cursor-culture-incorrect

Fix cursors sent to osu-web being potentially string formatted in incorrect culture
This commit is contained in:
Bartłomiej Dach
2022-01-04 19:27:14 +01:00
committed by GitHub
Unverified
+3 -1
View File
@@ -1,6 +1,8 @@
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
// See the LICENCE file in the repository root for full licence text.
using System.Globalization;
using Newtonsoft.Json.Linq;
using osu.Framework.IO.Network;
using osu.Framework.Extensions.IEnumerableExtensions;
using osu.Game.Online.API.Requests;
@@ -16,7 +18,7 @@ namespace osu.Game.Extensions
{
cursor?.Properties.ForEach(x =>
{
webRequest.AddParameter("cursor[" + x.Key + "]", x.Value.ToString());
webRequest.AddParameter("cursor[" + x.Key + "]", (x.Value as JValue)?.ToString(CultureInfo.InvariantCulture) ?? x.Value.ToString());
});
}
}