1
0
mirror of https://github.com/searxng/searxng.git synced 2024-11-19 02:40:11 +01:00

hide suggestions box if empty

This bug happens only in python3
because map returns an iterator.
This commit is contained in:
Marc Abonce Seguin 2019-08-25 23:01:30 -07:00
parent 5706c12fba
commit 495ae59b31

View File

@ -606,11 +606,11 @@ def index():
# HTML output format
# suggestions: use RawTextQuery to get the suggestion URLs with the same bang
suggestion_urls = map(lambda suggestion: {
suggestion_urls = list(map(lambda suggestion: {
'url': raw_text_query.changeSearchQuery(suggestion).getFullQuery(),
'title': suggestion
},
result_container.suggestions)
result_container.suggestions))
correction_urls = list(map(lambda correction: {
'url': raw_text_query.changeSearchQuery(correction).getFullQuery(),