cbmi/account/signals.py
2013-10-19 00:47:24 +02:00

9 lines
No EOL
306 B
Python

def create_profile(sender, instance, signal, created, **kwargs):
from account.models import UserProfile
if created:
UserProfile(user=instance).save()
def delete_profile(sender, instance, signal, **kwargs):
from account.models import UserProfile
UserProfile(user=instance).delete()