From 5c6a8dfba29a57cbf149794e05211a992c414750 Mon Sep 17 00:00:00 2001 From: Marcel Gansfusz Date: Thu, 23 Oct 2025 15:40:45 +0200 Subject: [PATCH] fixed bug in js, that blocked showing prof suggestions when nothing is entered in the field --- static/autocomplete.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/static/autocomplete.js b/static/autocomplete.js index 6824849..959a694 100644 --- a/static/autocomplete.js +++ b/static/autocomplete.js @@ -21,7 +21,7 @@ function autocomplete(inp, type) { i, apirq, iname, - val = this.value; + val = inp.value; /*close any already open lists of autocompleted values*/ closeAllLists(); if (!val && type === "lva" && pid === null) { @@ -56,7 +56,7 @@ function autocomplete(inp, type) { a.setAttribute("id", this.id + "autocomplete-list"); a.setAttribute("class", "autocomplete-items"); /*append the DIV element as a child of the autocomplete container:*/ - this.parentNode.appendChild(a); + inp.parentNode.appendChild(a); /*for each item in the array...*/ //await response; if (response.ok) {