From 29e5e66c5fe0c25c9309be3236f02a1a8776ead1 Mon Sep 17 00:00:00 2001 From: Cayo Puigdefabregas Date: Thu, 26 Oct 2023 18:09:07 +0200 Subject: [PATCH] add method un did model --- idhub/models.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/idhub/models.py b/idhub/models.py index 2570d34..52f3010 100644 --- a/idhub/models.py +++ b/idhub/models.py @@ -23,6 +23,12 @@ class DID(models.Model): ) # kind = "KEY|WEB" + @property + def is_organization_did(self): + if not self.user: + return True + return False + class Schemas(models.Model): file_schema = models.CharField(max_length=250)