release(v2.3.4): fix(admin): use textContent for footer preview to satisfy CodeQL

This commit is contained in:
Ryan
2025-12-05 05:09:42 -05:00
committed by GitHub
parent b06c44a5ba
commit bb0ac9f421
2 changed files with 7 additions and 3 deletions

View File

@@ -1,5 +1,9 @@
# Changelog # Changelog
## Changes 12/5/2025 (v2.3.4)
release(v2.3.4): fix(admin): use textContent for footer preview to satisfy CodeQL
## Changes 12/5/2025 (v2.3.3) ## Changes 12/5/2025 (v2.3.3)
release(v2.3.3): footer branding, Pro bundle UX + file list polish release(v2.3.3): footer branding, Pro bundle UX + file list polish

View File

@@ -117,12 +117,12 @@ function applyFooterFromAdmin() {
const val = (document.getElementById('brandingFooterHtml')?.value || '').trim(); const val = (document.getElementById('brandingFooterHtml')?.value || '').trim();
if (val) { if (val) {
// Allow HTML here rely on backend sanitizing what gets stored. // Show raw text in the live preview; HTML will be rendered on real page load
footerEl.innerHTML = val; footerEl.textContent = val;
} else { } else {
const year = new Date().getFullYear(); const year = new Date().getFullYear();
footerEl.innerHTML = footerEl.innerHTML =
`&copy; ${year}&nbsp;<a href="https://filerise.net" target="_blank" rel="noopener noreferrer">FileRise</a>`; `&copy; ${year}&nbsp;<a href="https://filerise.net" target="_blank" rel="noopener noreferrer">FileRise</a>`;
} }
} catch (e) { } catch (e) {
console.warn('Failed to live-update footer from admin panel', e); console.warn('Failed to live-update footer from admin panel', e);