Django 1.10: User.is_authenticated is now a property

This commit is contained in:
Raphael Michel
2016-09-27 10:25:20 +02:00
parent fbd1c0d367
commit 3e318d0dcf
6 changed files with 11 additions and 11 deletions

View File

@@ -15,7 +15,7 @@ class LocaleSet(View):
locale = request.GET.get('locale')
if locale in [lc for lc, ll in settings.LANGUAGES]:
if request.user.is_authenticated():
if request.user.is_authenticated:
request.user.locale = locale
request.user.save()