From d02239816a99b2b6ee1c43e2dc70aff4e6052b9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn-Michael=20Miehe?= <40151420+ldericher@users.noreply.github.com> Date: Wed, 30 Mar 2022 02:16:06 +0000 Subject: [PATCH] admin can login --- api/kiwi_vpn_api/db/user.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/kiwi_vpn_api/db/user.py b/api/kiwi_vpn_api/db/user.py index e8f41fc..54e0d2b 100644 --- a/api/kiwi_vpn_api/db/user.py +++ b/api/kiwi_vpn_api/db/user.py @@ -143,7 +143,8 @@ class User(UserBase, table=True): # password hash mismatch return None - if user.has_tag(TagValue.login): + if not (user.has_tag(TagValue.login) + or user.has_tag(TagValue.admin)): # no login permission return None