]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix changelog entries with brackets crashing the client (#36033)
authorTayrtahn <tayrtahn@gmail.com>
Sun, 23 Mar 2025 23:46:34 +0000 (19:46 -0400)
committerGitHub <noreply@github.com>
Sun, 23 Mar 2025 23:46:34 +0000 (00:46 +0100)
Content.Client/Changelog/ChangelogTab.xaml.cs

index ca86f8a6b2e4cb08221761b7cd9af5da8b229aeb..851ed2042200117ed623e147fdbe55c11bb81e09 100644 (file)
@@ -131,13 +131,13 @@ public sealed partial class ChangelogTab : Control
                     Margin = new Thickness(6, 0, 0, 0),
                 };
                 authorLabel.SetMessage(
-                    FormattedMessage.FromMarkupOrThrow(Loc.GetString("changelog-author-changed", ("author", author))));
+                    FormattedMessage.FromMarkupOrThrow(Loc.GetString("changelog-author-changed", ("author", FormattedMessage.EscapeText(author)))));
                 ChangelogBody.AddChild(authorLabel);
 
                 foreach (var change in groupedEntry.SelectMany(c => c.Changes))
                 {
                     var text = new RichTextLabel();
-                    text.SetMessage(FormattedMessage.FromMarkupOrThrow(change.Message));
+                    text.SetMessage(FormattedMessage.FromUnformatted(change.Message));
                     ChangelogBody.AddChild(new BoxContainer
                     {
                         Orientation = LayoutOrientation.Horizontal,