from django.dispatch import receiver

from allauth.account.signals import user_signed_up

from .models import ClientProfile


@receiver(user_signed_up)
def ensure_client_profile(sender, request, user, **kwargs):
    ClientProfile.objects.get_or_create(user=user)
