1
0
mirror of https://gitlab.crans.org/bde/nk20 synced 2025-02-11 09:41:17 +00:00
nk20/apps/member/signals.py
Pierre-antoine Comby 633663f95d add signup view
2019-08-11 16:22:52 +02:00

16 lines
408 B
Python

#!/usr/bin/env python
# -*- mode: python; coding: utf-8 -*-
# Copyright (C) 2018-2019 by BDE ENS Paris-Saclay
# SPDX-License-Identifier: GPL-3.0-or-later
def save_user_profile(instance, created, **_kwargs):
"""
Hook to create and save a note when an user is updated
"""
if created:
from .models import Profile
Profile.objects.create(user=instance)
instance.note.save()