From bb4beab5eb26de74e7efc3370e8fadb9f7b56f87 Mon Sep 17 00:00:00 2001 From: Dmytro <98233552+DmytroAlipov@users.noreply.github.com> Date: Tue, 11 Jul 2023 00:25:06 +0300 Subject: [PATCH] fix: Incorrect symbols on wiki create article page (#32628) The message was being double-escaped by React with the StatusAlertRenderer. This fixes the problem by removing the first layer of HTML-escaping so it is only escaped once. --- lms/templates/wiki/base.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lms/templates/wiki/base.html b/lms/templates/wiki/base.html index 8ca99f2d5d..c28a38a2c7 100644 --- a/lms/templates/wiki/base.html +++ b/lms/templates/wiki/base.html @@ -76,11 +76,15 @@ {% block wiki_breadcrumbs %}{% endblock %} {% if messages %} + {% comment %} + The message is not actually safe, but StatusAlertRenderer uses react which adds escaping, + so marking as safe keeps the message from being double-escaped. + {% endcomment %} {% for message in messages %}