on master help sign in
[fix] xpath, mojeek: fix commit 58d72f26925d56e22330c54be03c3dcbee0c4135

before commit 58d72f2, category was not set in xpath.py, so searx/engines/__init__py was setting the category to ['general'] the commit 58d72f2 set the category to [] which is not replaced by searx/engines/__init__.py consequence: the mojeek engine is hidden in the preferences. this commit revert the xpath.py change. close #2368

commitd41cafd5f3554f2adf6728b4ffaafd6c8a49a1ce authorAlexandre Flament <alex@al-f.net> dateThu 10 Dec 2020, 10:40 (6 years ago) parent820b468
1 file changed+1−2
searx/engines/xpath.py+1−2
searx/engines/xpath.py+1−2
@@ -7,7 +7,6 @@ url_xpath = None
77content_xpath = None
88title_xpath = None
99thumbnail_xpath = False
10−categories = []
1110paging = False
1211suggestion_xpath = ''
1312results_xpath = ''
@@ -39,7 +38,7 @@ def request(query, params):
3938def response(resp):
4039 results = []
4140 dom = html.fromstring(resp.text)
42− is_onion = True if 'onions' in categories else False
41+ is_onion = True if 'onions' in categories else False # pylint: disable=undefined-variable
4342
4443 if results_xpath:
4544 for result in eval_xpath_list(dom, results_xpath):