SearXNG is a free internet metasearch engine which aggregates results from various search services and databases. Users are neither tracked nor profiled.
Python bingbravedegoogleduckduckgogooglemetasearchprivacypythonqwantsearchsearch-enginesearxsearxngstartpageyahoo
[fix] fixes google play engines (#1651)
Alexandre Flamentf34b5cedb11b
diff --git a/searx/engines/xpath.py b/searx/engines/xpath.pyindex a5f30d86d..61494ce4e 100644--- a/searx/engines/xpath.py+++ b/searx/engines/xpath.py@@ -111,13 +111,10 @@ def response(resp):tmp_result = {'url': url, 'title': title, 'content': content}# add thumbnail if available- thumbnail = Noneif thumbnail_xpath:- thumbnail = extract_url(- result.xpath(thumbnail_xpath), search_url- )- if thumbnail:- tmp_result['img_src'] = thumbnail+ thumbnail_xpath_result = result.xpath(thumbnail_xpath)+ if len(thumbnail_xpath_result) > 0:+ tmp_result['img_src'] = extract_url(thumbnail_xpath_result, search_url)results.append(tmp_result)else:diff --git a/searx/settings.yml b/searx/settings.ymlindex 56d9bccd0..bee7aed7e 100644--- a/searx/settings.yml+++ b/searx/settings.yml@@ -321,7 +321,7 @@ engines:title_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a'url_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a/@href'content_xpath : './/div[@class="RZEgze"]//a[@class="mnKHRc"]'- thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]/img/@data-src'+ thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]//img/@data-src'categories : filesshortcut : gpadisabled : True@@ -333,7 +333,7 @@ engines:title_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a'url_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a/@href'content_xpath : './/div[@class="RZEgze"]//a[@class="mnKHRc"]'- thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]/img/@data-src'+ thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]//img/@data-src'categories : videosshortcut : gpmdisabled : True@@ -345,7 +345,7 @@ engines:title_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a'url_xpath : './/div[@class="RZEgze"]//div[@title and not(@title="")]/a/@href'content_xpath : './/div[@class="RZEgze"]//a[@class="mnKHRc"]'- thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]/img/@data-src'+ thumbnail_xpath : './/div[@class="uzcko"]/div/span[1]//img/@data-src'categories : musicshortcut : gpsdisabled : True