Selaa lähdekoodia

Fixed bug in user creation

Denis Merigoux 9 vuotta sitten
vanhempi
commit
33f1d98815
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1 1
      counter/views.py

+ 1 - 1
counter/views.py

@@ -386,7 +386,7 @@ def createUser(request):
386 386
         nick = data['nick'][0]
387 387
         password1 = data['password1'][0]
388 388
         password2 = data['password2'][0]
389
-        email_notifications = (data['email_notifications'][0] == "on")
389
+        email_notifications = ('email_notifications' in data.keys())
390 390
 
391 391
         if password1 != password2:
392 392
             error = "Les deux mots de passe sont différents."