mirror of
				https://gitlab.crans.org/bde/nk20
				synced 2025-10-31 15:50:03 +01:00 
			
		
		
		
	superusers at creation gets automatically valid registration
This commit is contained in:
		| @@ -13,4 +13,7 @@ def save_user_profile(instance, created, raw, **_kwargs): | ||||
|     if created and instance.is_active: | ||||
|         from .models import Profile | ||||
|         Profile.objects.get_or_create(user=instance) | ||||
|         if instance.is_superuser: | ||||
|             instance.profile.email_confirmed = True | ||||
|             instance.profile.registration_valid = True | ||||
|         instance.profile.save() | ||||
|   | ||||
		Reference in New Issue
	
	Block a user