Logging is finally processed at post saved, but old instance is querried
This commit is contained in:
parent
bcee5f8f2f
commit
9cd050e2f0
3 changed files with 21 additions and 11 deletions
|
|
@ -1,7 +1,7 @@
|
|||
# Copyright (C) 2018-2020 by BDE ENS Paris-Saclay
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
|
||||
def save_user_note(instance, created, raw, **_kwargs):
|
||||
def save_user_profile(instance, created, raw, **_kwargs):
|
||||
"""
|
||||
Hook to create and save a profile when an user is updated if it is not registered with the signup form
|
||||
"""
|
||||
|
|
@ -11,5 +11,5 @@ def save_user_note(instance, created, raw, **_kwargs):
|
|||
|
||||
if created:
|
||||
from .models import Profile
|
||||
Profile.objects.get_or_create(user=instance)
|
||||
#Profile.objects.get_or_create(user=instance)
|
||||
instance.profile.save()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue