mirror of https://github.com/searxng/searxng.git
[fix] gettext requires request.preferences
This commit is contained in:
parent
028e5b43d4
commit
827f9e41ca
|
@ -369,11 +369,11 @@ def pre_request():
|
||||||
request.errors = []
|
request.errors = []
|
||||||
|
|
||||||
preferences = Preferences(themes, categories.keys(), engines, plugins)
|
preferences = Preferences(themes, categories.keys(), engines, plugins)
|
||||||
|
request.preferences = preferences
|
||||||
try:
|
try:
|
||||||
preferences.parse_cookies(request.cookies)
|
preferences.parse_cookies(request.cookies)
|
||||||
except:
|
except:
|
||||||
request.errors.append(gettext('Invalid settings, please edit your preferences'))
|
request.errors.append(gettext('Invalid settings, please edit your preferences'))
|
||||||
request.preferences = preferences
|
|
||||||
|
|
||||||
# merge GET, POST vars
|
# merge GET, POST vars
|
||||||
# request.form
|
# request.form
|
||||||
|
|
Loading…
Reference in New Issue