Revert "remove 'all' option from search languages"

This reverts commit 4d1770398a.
This commit is contained in:
Noémi Ványi 2019-01-06 15:27:46 +01:00
parent 491792c1a5
commit b63d645a52
51 changed files with 245 additions and 70 deletions

View file

@ -24,7 +24,7 @@ from flask_babel import gettext
import requests.exceptions
import searx.poolrequests as requests_lib
from searx.engines import (
categories, engines, settings
categories, engines
)
from searx.answerers import ask
from searx.utils import gen_useragent
@ -221,10 +221,6 @@ def get_search_query_from_webapp(preferences, form):
else:
query_lang = preferences.get_value('language')
# provides backwards compatibility for requests using old language default
if query_lang == 'all':
query_lang = settings['search']['language']
# check language
if not VALID_LANGUAGE_CODE.match(query_lang):
raise SearxParameterException('language', query_lang)