mirror of
https://github.com/searxng/searxng
synced 2024-01-01 19:24:07 +01:00
[fix] settings: javascript crash when entering due to missing search form
This commit is contained in:
parent
8d2c01e4ce
commit
c8e932647b
1 changed files with 14 additions and 12 deletions
|
@ -186,6 +186,7 @@
|
|||
|
||||
// override form submit action to update the actually selected categories
|
||||
const form = d.querySelector("#search");
|
||||
if (form != null) {
|
||||
searxng.on(form, 'submit', (event) => {
|
||||
event.preventDefault();
|
||||
const categoryValuesInput = d.querySelector("#selected-categories");
|
||||
|
@ -200,6 +201,7 @@
|
|||
}
|
||||
form.submit();
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
})(window, document, window.searxng);
|
||||
|
|
Loading…
Add table
Reference in a new issue