From df8e34b97ff34ea14a2d4d2dc2734878ad6336be Mon Sep 17 00:00:00 2001 From: Linty Date: Fri, 9 Feb 2024 17:38:03 +0100 Subject: [PATCH] (cp 562170528) turn code more robust by using sprintf instead of replace --- admin/themes/default/js/history.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/themes/default/js/history.js b/admin/themes/default/js/history.js index b7b6cad1d..bd5e634ee 100644 --- a/admin/themes/default/js/history.js +++ b/admin/themes/default/js/history.js @@ -489,7 +489,7 @@ function lineConstructor(line, id, imageDisplay) { count_more++; return `${str_search_details[key]} : ${value_str}`; }).join('
'); - newLine.find(".detail-item-3").html(str_and_more.replace('%d', count_more)).addClass('icon-info-circled-1 tiptip'); + newLine.find(".detail-item-3").html(sprintf(str_and_more, count_more)).addClass('icon-info-circled-1 tiptip'); newLine.find(".detail-item-3").attr('title', search_details_str).removeClass('hide'); } break;