mirror of https://gitlab.crans.org/bde/nk20
Delete the soge credit if the user declares that one was opened but in the validation form the checkbox was unchecked
This commit is contained in:
parent
0b1bed8048
commit
2f68601e8b
|
@ -317,7 +317,7 @@ class FutureUserDetailView(ProtectQuerysetMixin, LoginRequiredMixin, FormMixin,
|
|||
user.profile.save()
|
||||
user.refresh_from_db()
|
||||
|
||||
if not soge and SogeCredit.objects.filter(user=user).exists:
|
||||
if not soge and SogeCredit.objects.filter(user=user).exists():
|
||||
# If the user declared that a bank account was opened but in the validation form the SoGé case was
|
||||
# unchecked, delete the associated credit
|
||||
soge_credit = SogeCredit.objects.get(user=user)
|
||||
|
|
Loading…
Reference in New Issue