fix(xss): sanitize on input itself

This commit is contained in:
sokumon 2025-10-06 17:01:30 +05:30
parent 09c1d84a45
commit 4a8391a6fc

View file

@ -66,6 +66,7 @@ frappe.search.AwesomeBar = class AwesomeBar {
"input",
frappe.utils.debounce(function (e) {
var value = e.target.value;
value = frappe.utils.xss_sanitise(value);
var txt = value.trim().replace(/\s\s+/g, " ");
var last_space = txt.lastIndexOf(" ");
me.global_results = [];