mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 06:42:16 +00:00
Removed the check, we want to force deletion
This commit is contained in:
@@ -180,8 +180,7 @@ class ServiceAccount(models.Model):
|
||||
@staticmethod
|
||||
def pre_delete_listener( **kwargs ):
|
||||
api = kwargs['instance'].service.api_class
|
||||
if api.check_user(kwargs['instance'].service_uid):
|
||||
if not api.delete_user(kwargs['instance'].service_uid):
|
||||
raise ServiceError('Unable to delete account on related service')
|
||||
if not api.delete_user(kwargs['instance'].service_uid):
|
||||
raise ServiceError('Unable to delete account on related service')
|
||||
|
||||
signals.pre_delete.connect(ServiceAccount.pre_delete_listener, sender=ServiceAccount)
|
||||
|
||||
Reference in New Issue
Block a user