Browse Source

Merge pull request #337 from MrPaulBlack/fix-searxjs-null-exception

[fix] fix searx.js null pointer because of missing category div
Alexandre Flament 3 years ago
parent
commit
e63410d2f4

File diff suppressed because it is too large
+ 0 - 0
searx/static/themes/oscar/css/pointhi.min.css.map


+ 1 - 1
searx/static/themes/simple/js/searx.js

@@ -782,7 +782,7 @@ searx.ready(function() {
     }
     }
 
 
     // vanilla js version of search_on_category_select.js
     // vanilla js version of search_on_category_select.js
-    if (qinput !== null && searx.search_on_category_select) {
+    if (qinput !== null && d.querySelector('.help') != null && searx.search_on_category_select) {
       d.querySelector('.help').className='invisible';
       d.querySelector('.help').className='invisible';
 
 
       searx.on('#categories input', 'change', function() {
       searx.on('#categories input', 'change', function() {

File diff suppressed because it is too large
+ 0 - 0
searx/static/themes/simple/js/searx.min.js


File diff suppressed because it is too large
+ 0 - 0
searx/static/themes/simple/js/searx.min.js.map


+ 1 - 1
searx/static/themes/simple/src/js/main/searx_search.js

@@ -96,7 +96,7 @@
     }
     }
 
 
     // vanilla js version of search_on_category_select.js
     // vanilla js version of search_on_category_select.js
-    if (qinput !== null && searx.search_on_category_select) {
+    if (qinput !== null && d.querySelector('.help') != null && searx.search_on_category_select) {
       d.querySelector('.help').className='invisible';
       d.querySelector('.help').className='invisible';
 
 
       searx.on('#categories input', 'change', function() {
       searx.on('#categories input', 'change', function() {

Some files were not shown because too many files changed in this diff