diff --git a/api/kiwi_vpn_api/db/schemas.py b/api/kiwi_vpn_api/db/schemas.py index 4f17168..04122de 100644 --- a/api/kiwi_vpn_api/db/schemas.py +++ b/api/kiwi_vpn_api/db/schemas.py @@ -161,6 +161,9 @@ class User(UserBase): # user already existed pass + def is_admin(self) -> bool: + return UserCapability.admin in self.capabilities + def authenticate( self, db: Session,