mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-02-09 15:10:36 +00:00
style: apply ruff
This commit is contained in:
@@ -132,9 +132,7 @@ class RowLevelSecurityConstraint(models.BaseConstraint):
|
|||||||
path, _, kwargs = super().deconstruct()
|
path, _, kwargs = super().deconstruct()
|
||||||
return (path, (self.target_field,), kwargs)
|
return (path, (self.target_field,), kwargs)
|
||||||
|
|
||||||
def validate(
|
def validate(self, model, instance, exclude=None, using=DEFAULT_DB_ALIAS): # noqa: F841
|
||||||
self, model, instance, exclude=None, using=DEFAULT_DB_ALIAS
|
|
||||||
): # noqa: F841
|
|
||||||
if not hasattr(instance, "tenant_id"):
|
if not hasattr(instance, "tenant_id"):
|
||||||
raise ValidationError(f"{model.__name__} does not have a tenant_id field.")
|
raise ValidationError(f"{model.__name__} does not have a tenant_id field.")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user