commit: dd900b25a9a7eee93d145d0316bf119d85b30e64
parent: 7a9b18e9e9847252549408108ec72c1c8d2296b7
Author: Adam Tauber <asciimoo@gmail.com>
Date: Fri, 3 Nov 2017 20:18:51 +0100
Merge pull request #1078 from kvch/result-engines-set
results: make engines of results set
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/searx/results.py b/searx/results.py
@@ -197,7 +197,7 @@ class ResultContainer(object):
result['parsed_url'] = result['parsed_url']._replace(scheme="http")
result['url'] = result['parsed_url'].geturl()
- result['engines'] = [result['engine']]
+ result['engines'] = set([result['engine']])
# strip multiple spaces and cariage returns from content
if result.get('content'):
@@ -227,7 +227,7 @@ class ResultContainer(object):
duplicated['positions'].append(position)
# add engine to list of result-engines
- duplicated['engines'].append(result['engine'])
+ duplicated['engines'].add(result['engine'])
# using https if possible
if duplicated['parsed_url'].scheme != 'https' and result['parsed_url'].scheme == 'https':