mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-22 11:23:10 +00:00
Improve check did_set_initial_passwd in new_user
This commit is contained in:
parent
c00bb2573b
commit
aad7110fd2
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