diff options
author | Noémi Ványi <sitbackandwait@gmail.com> | 2017-07-19 17:23:54 +0200 |
---|---|---|
committer | Adam Tauber <asciimoo@gmail.com> | 2017-07-20 13:30:56 +0200 |
commit | 2242000bd4e9491e9f8d15568b4387540096a982 (patch) | |
tree | c975139d9f7d3a50376e7d8de8cc8c7e26f45486 /searx/results.py | |
parent | c30f73f8fda2b51cfd95967a29cc34a2036ffddd (diff) | |
download | searxng-2242000bd4e9491e9f8d15568b4387540096a982.tar.gz searxng-2242000bd4e9491e9f8d15568b4387540096a982.zip |
change unresponsive_engines to a set to eliminate duplication of errors
Diffstat (limited to 'searx/results.py')
-rw-r--r-- | searx/results.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/searx/results.py b/searx/results.py index a7b2e385d..badd86ddb 100644 --- a/searx/results.py +++ b/searx/results.py @@ -135,7 +135,7 @@ class ResultContainer(object): self._number_of_results = [] self._ordered = False self.paging = False - self.unresponsive_engines = [] + self.unresponsive_engines = set() def extend(self, engine_name, results): for result in list(results): @@ -306,5 +306,5 @@ class ResultContainer(object): return 0 return resultnum_sum / len(self._number_of_results) - def add_unresponsive_engine(self, engine_name): - self.unresponsive_engines.append(engine_name) + def add_unresponsive_engine(self, engine_error): + self.unresponsive_engines.add(engine_error) |