aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorBonfaceKilz2021-10-20 14:11:16 +0300
committerBonfaceKilz2021-10-25 14:00:14 +0300
commitd32f0e0f56827c653902456b50ed71911a795a3c (patch)
tree95112e6699458c20a2df092006927dbff56a033b /wqflask
parentfbffb2e4f7538cc34332f37064d4b67cd52588fb (diff)
downloadgenenetwork2-d32f0e0f56827c653902456b50ed71911a795a3c.tar.gz
decorators: Use the correct logic to check for edit_admins_access
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/decorators.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/wqflask/wqflask/decorators.py b/wqflask/wqflask/decorators.py
index cd06aee7..843539ee 100644
--- a/wqflask/wqflask/decorators.py
+++ b/wqflask/wqflask/decorators.py
@@ -88,7 +88,7 @@ def edit_admins_access_required(f):
except:
response = {}
if max([AdminRole(role) for role in response.get(
- "data", ["not-admin"])]) >= AdminRole.EDIT_ADMINS:
+ "admin", ["not-admin"])]) < AdminRole.EDIT_ADMINS:
return "You need to have edit-admins access", 401
return f(*args, **kwargs)
return wrap