fix: remove redundant badge element lookup in edit inspection modal

This commit is contained in:
kdeterme 2026-09-18 14:12:21 +02:00
parent ecb3bbddd1
commit 3bec7cfd7c

View file

@ -885,9 +885,6 @@ document.addEventListener('DOMContentLoaded', function() {
badgeText = '{% translate "Suggéré : Non conforme" %}'; badgeText = '{% translate "Suggéré : Non conforme" %}';
badgeClass = 'bg-warning-subtle text-warning-emphasis border border-warning-subtle'; badgeClass = 'bg-warning-subtle text-warning-emphasis border border-warning-subtle';
icon = 'bi-exclamation-circle-fill'; icon = 'bi-exclamation-circle-fill';
}
const badge = document.getElementById('editHotboxRecommendedBadge');
if (badge) { if (badge) {
badge.className = `badge ${badgeClass} px-2.5 py-1 rounded-pill small`; badge.className = `badge ${badgeClass} px-2.5 py-1 rounded-pill small`;
badge.innerHTML = `<i class="bi ${icon} me-1"></i>${badgeText}`; badge.innerHTML = `<i class="bi ${icon} me-1"></i>${badgeText}`;