1👍
You’re looking for signals. Add signals.py
to your app and then
# handle signal
def user_registered(sender, user, request, **kwarg):
user.is_superuser = True
user.save()
# register signal
user_registered.connect(user_registered)
See explanation at https://django-registration.readthedocs.org/en/latest/signals.html
Source:stackexchange.com