logo

searx

Unnamed repository; edit this file 'description' to name the repository.
commit: ee8cabf496a27030c4035266e92c792ce294b013
parent: 58cc03351a10668da8aedd355d8b7da33057855a
Author: Adam Tauber <asciimoo@gmail.com>
Date:   Sat,  1 Nov 2014 17:49:18 +0100

Merge pull request #122 from pointhi/bugfix

[fix] #121, HTTP 500 Error if res["content"] == None

Diffstat:

searx/search.py | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/searx/search.py b/searx/search.py @@ -131,7 +131,7 @@ def score_results(results): weight = 1.0 # strip multiple spaces and cariage returns from content - if 'content' in res: + if res.get('content'): res['content'] = re.sub(' +', ' ', res['content'].strip().replace('\n', ''))