From fe77c20126e1f9f86fa3bcee5d7fd7d7ca94a063 Mon Sep 17 00:00:00 2001 From: Sebin Song Date: Wed, 22 Jan 2025 13:36:10 +0900 Subject: [PATCH] #2529 - Fix the chat regression (#2533) * fix the extra br tag issues * better comment --- frontend/views/utils/markdown-utils.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/views/utils/markdown-utils.js b/frontend/views/utils/markdown-utils.js index e8214b644..9be7635b4 100644 --- a/frontend/views/utils/markdown-utils.js +++ b/frontend/views/utils/markdown-utils.js @@ -57,6 +57,11 @@ export function renderMarkdown (str: string): any { converted = converted.replace(/<([a-z]+)>\n/g, '<$1>') .replace(/\n<\/([a-z]+)>/g, '') + // STEP 4. Sanitize some
s that directly precedes/follows