summaryrefslogtreecommitdiff
path: root/searx/engines/yacy.py
diff options
context:
space:
mode:
authorasciimoo <asciimoo@gmail.com>2014-02-11 13:13:51 +0100
committerasciimoo <asciimoo@gmail.com>2014-02-11 13:13:51 +0100
commitc1d7d30b8ec2950a6338f0b99ebe9bdc094fdb73 (patch)
treebc2a38ccacc7d94721ab4b3942d83617ef3662f6 /searx/engines/yacy.py
parent239299d45ec7698e45451b617f2ef52bfb2c2e88 (diff)
downloadsearxng-c1d7d30b8ec2950a6338f0b99ebe9bdc094fdb73.tar.gz
searxng-c1d7d30b8ec2950a6338f0b99ebe9bdc094fdb73.zip
[mod] len() removed from conditions
Diffstat (limited to 'searx/engines/yacy.py')
-rw-r--r--searx/engines/yacy.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/searx/engines/yacy.py b/searx/engines/yacy.py
index a4a41ac3b..efdf846ac 100644
--- a/searx/engines/yacy.py
+++ b/searx/engines/yacy.py
@@ -13,7 +13,7 @@ def request(query, params):
def response(resp):
raw_search_results = loads(resp.text)
- if not len(raw_search_results):
+ if not raw_search_results:
return []
search_results = raw_search_results.get('channels', {})[0].get('items', [])
@@ -26,10 +26,10 @@ def response(resp):
tmp_result['url'] = result['link']
tmp_result['content'] = ''
- if len(result['description']):
+ if result['description']:
tmp_result['content'] += result['description'] + "<br/>"
- if len(result['pubDate']):
+ if result['pubDate']:
tmp_result['content'] += result['pubDate'] + "<br/>"
if result['size'] != '-1':