[fix] gettext requires request.preferences

This commit is contained in:
Adam Tauber 2016-11-15 09:56:18 +01:00
parent 028e5b43d4
commit 827f9e41ca
1 changed files with 1 additions and 1 deletions

View File

@ -369,11 +369,11 @@ def pre_request():
request.errors = []
preferences = Preferences(themes, categories.keys(), engines, plugins)
request.preferences = preferences
try:
preferences.parse_cookies(request.cookies)
except:
request.errors.append(gettext('Invalid settings, please edit your preferences'))
request.preferences = preferences
# merge GET, POST vars
# request.form