diff --git a/app/authentification/utils.py b/app/authentification/utils.py index deba90f4..f6d10d40 100644 --- a/app/authentification/utils.py +++ b/app/authentification/utils.py @@ -16,8 +16,8 @@ def activate(request, uidb64, token): if user is not None and account_activation_token.check_token(user, token): user.is_active = True user.save() - login(request=request, user=user, - backend='django.contrib.auth.backends.ModelBackend') + user.backend = 'django.contrib.auth.backends.ModelBackend' + login(request=request, user=user,) return redirect('projects') else: return render(request, 'validate_mail_address_invalid.html')