mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-09-12 01:03:09 +00:00
Improve check did_set_initial_passwd in new_user
This commit is contained in:
parent
e6680e0717
commit
f7259ae69b
2 changed files with 1 additions and 2 deletions
|
@ -504,7 +504,6 @@ class AdherentCreationForm(AdherentForm):
|
||||||
if set_passwd:
|
if set_passwd:
|
||||||
user.set_password(self.cleaned_data["password1"])
|
user.set_password(self.cleaned_data["password1"])
|
||||||
|
|
||||||
user.did_set_initial_passwd = set_passwd
|
|
||||||
user.save()
|
user.save()
|
||||||
return user
|
return user
|
||||||
|
|
||||||
|
|
|
@ -126,7 +126,7 @@ def new_user(request):
|
||||||
if user.is_valid():
|
if user.is_valid():
|
||||||
user = user.save()
|
user = user.save()
|
||||||
|
|
||||||
if user.did_set_initial_passwd:
|
if user.pwd_ntlm:
|
||||||
user.send_confirm_email_if_necessary(request)
|
user.send_confirm_email_if_necessary(request)
|
||||||
messages.success(
|
messages.success(
|
||||||
request,
|
request,
|
||||||
|
|
Loading…
Reference in a new issue