summaryrefslogtreecommitdiff
path: root/searx/webapp.py
diff options
context:
space:
mode:
authorThomas Pointhuber <thomas.pointhuber@gmx.at>2015-01-10 19:55:21 +0100
committerThomas Pointhuber <thomas.pointhuber@gmx.at>2015-01-10 19:55:21 +0100
commitc19b0899a415fa3be7c1f30258c218868ef0b671 (patch)
treef54c6dbd993e7611ba5d69dd896789cdf5adbc7e /searx/webapp.py
parenteb6f3348c43f3456fa40716589967ec8a5ec53e2 (diff)
downloadsearxng-c19b0899a415fa3be7c1f30258c218868ef0b671.tar.gz
searxng-c19b0899a415fa3be7c1f30258c218868ef0b671.zip
[fix] little autocompleter fix
Diffstat (limited to 'searx/webapp.py')
-rw-r--r--searx/webapp.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/searx/webapp.py b/searx/webapp.py
index 3dcba2968..bd79e0035 100644
--- a/searx/webapp.py
+++ b/searx/webapp.py
@@ -355,8 +355,10 @@ def autocompleter():
# parse searx specific autocompleter results like !bang
raw_results = searx_bang(query)
- # run autocompletion
- raw_results.extend(completer(query.getSearchQuery()))
+ # normal autocompletion results only appear if max 3. searx results returned
+ if len(raw_results) <= 3:
+ # run autocompletion
+ raw_results.extend(completer(query.getSearchQuery()))
# parse results (write :language and !engine back to result string)
results = []