summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorAdam Tauber <asciimoo@gmail.com>2016-12-10 00:06:39 +0100
committerGitHub <noreply@github.com>2016-12-10 00:06:39 +0100
commitceb8ae6439f092dad6e26406cd178c2195eb0898 (patch)
tree8b285b2dd483006d08c03b9fec49cba49ff16a87 /searx/webapp.py
parentd80fb2c8e8995facb3a25c152c47a93eecf1fee4 (diff)
parente48f07a367e55bf8aa881902b977bd7ce1cd2bb6 (diff)
Merge pull request #751 from dalf/searchpy2
Simplify search.py
Diffstat (limited to 'searx/webapp.py')
-rw-r--r--searx/webapp.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index cdac52a45..7d4936f18 100644
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -601,6 +601,8 @@ def preferences():
if e.timeout > settings['outgoing']['request_timeout']:
stats[e.name]['warn_timeout'] = True
+ # get first element [0], the engine time,
+ # and then the second element [1] : the time (the first one is the label)
for engine_stat in get_engines_stats()[0][1]:
stats[engine_stat.get('name')]['time'] = round(engine_stat.get('avg'), 3)
if engine_stat.get('avg') > settings['outgoing']['request_timeout']: