From a980b90c0a888df945a0ba74f5621db7cfec32b7 Mon Sep 17 00:00:00 2001 From: koko210Serve Date: Sat, 2 May 2026 15:27:18 +0300 Subject: [PATCH] fix: escape content in buildCollapsibleSection, avoid double-escaping response --- bot/static/js/status.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bot/static/js/status.js b/bot/static/js/status.js index a40b07d..b9da96c 100644 --- a/bot/static/js/status.js +++ b/bot/static/js/status.js @@ -184,7 +184,7 @@ function renderPromptEntry(entry) { if (_middleTruncation && responseText.length > 400) { responseText = responseText.substring(0, 200) + '\n\n... [truncated middle] ...\n\n' + responseText.substring(responseText.length - 200); } - displayHtml += buildCollapsibleSection('Response', escapeHtml(responseText), 'response'); + displayHtml += buildCollapsibleSection('Response', responseText, 'response'); } // Render into the prompt-display div (using innerHTML for collapsible structure) @@ -249,7 +249,7 @@ function buildCollapsibleSection(title, content, sectionId) { ▼ ${escapeHtml(title)}
-
${content}
+
${escapeHtml(content)}
`; }