aboutsummaryrefslogtreecommitdiff
path: root/static/js/index.js
diff options
context:
space:
mode:
Diffstat (limited to 'static/js/index.js')
-rw-r--r--static/js/index.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/static/js/index.js b/static/js/index.js
index 7fc5785..62615e5 100644
--- a/static/js/index.js
+++ b/static/js/index.js
@@ -408,11 +408,9 @@
} else {
dropdown.removeAttribute("hidden");
for(const string in results.slice(0, 10)){
- const decode = document.createElement("textarea");
- decode.innerHTML = results[string].obj.title;
- let highlight = fuzzysort.highlight(fuzzysort.single(term, decode.value), "<span>", "</span>");
+ let highlight = fuzzysort.highlight(fuzzysort.single(term, results[string].obj.title), "<span>", "</span>");
if (highlight === null) {
- highlight = decode.value;
+ highlight = results[string].obj.title;
}
items = items + `
<li>