fix - bug of distribution serializer of quota stat

This commit is contained in:
2025-12-02 15:34:10 +03:30
parent 1af4308f32
commit 262a9275b7
3 changed files with 33 additions and 23 deletions

View File

@@ -545,7 +545,7 @@ class Quota(BaseModel):
stat = OrganizationQuotaStats.objects.filter(
quota=self,
)
return stat.first()
return stat.first() if stat.exists() else None
def soft_delete(self):
self.trash = True