diff options
author | asciimoo <asciimoo@gmail.com> | 2014-01-24 09:35:27 +0100 |
---|---|---|
committer | asciimoo <asciimoo@gmail.com> | 2014-01-24 09:35:27 +0100 |
commit | 85b81be35b9b53848431da2a4ab8d531990cf963 (patch) | |
tree | d0e97c66eb0c57932a1ca228d0b12746090a7a80 /searx/engines/startpage.py | |
parent | 99688d2c8e08ba579b67c31181489485f56c92d6 (diff) | |
download | searxng-85b81be35b9b53848431da2a4ab8d531990cf963.tar.gz searxng-85b81be35b9b53848431da2a4ab8d531990cf963.zip |
[fix] pep8
Diffstat (limited to 'searx/engines/startpage.py')
-rw-r--r-- | searx/engines/startpage.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/searx/engines/startpage.py b/searx/engines/startpage.py index 5a6c570d1..1b48baa8d 100644 --- a/searx/engines/startpage.py +++ b/searx/engines/startpage.py @@ -4,6 +4,7 @@ from lxml import html base_url = None search_url = None + def request(query, params): global search_url query = urlencode({'q': query})[2:] @@ -24,10 +25,10 @@ def response(resp): url = link.attrib.get('href') title = link.text_content() - content ='' + content = '' if len(result.xpath('./p[@class="desc"]')): content = result.xpath('./p[@class="desc"]')[0].text_content() - + results.append({'url': url, 'title': title, 'content': content}) - + return results |