aboutsummaryrefslogtreecommitdiff
path: root/wqflask/utility/authentication_tools.py
diff options
context:
space:
mode:
authorzsloan2020-07-28 12:51:54 -0500
committerzsloan2020-07-28 12:51:54 -0500
commit8e93afc7bcbb5bc12e43b0cdd2158894f633ae87 (patch)
treed1ba4c6a62023259679682f33e20bbc307955ab2 /wqflask/utility/authentication_tools.py
parent92088d72ad284a664eb1a53127c13ca2e6b4f602 (diff)
parent40f761b5b1f4e5fe24dde4ace91065f1007c0aa1 (diff)
downloadgenenetwork2-8e93afc7bcbb5bc12e43b0cdd2158894f633ae87.tar.gz
Merge branch 'testing' of github.com:genenetwork/genenetwork2 into testing
Diffstat (limited to 'wqflask/utility/authentication_tools.py')
-rw-r--r--wqflask/utility/authentication_tools.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/wqflask/utility/authentication_tools.py b/wqflask/utility/authentication_tools.py
index deddaec3..9a2a5ccd 100644
--- a/wqflask/utility/authentication_tools.py
+++ b/wqflask/utility/authentication_tools.py
@@ -45,7 +45,7 @@ def check_resource_availability(dataset, trait_id=None):
def add_new_resource(dataset, trait_id=None):
resource_ob = {
- 'owner_id' : "None",
+ 'owner_id' : "none", # webqtlConfig.DEFAULT_OWNER_ID,
'default_mask': webqtlConfig.DEFAULT_PRIVILEGES,
'group_masks' : {}
}
@@ -84,6 +84,7 @@ def check_admin(resource_id=None):
try:
response = json.loads(requests.get(the_url).content)['admin']
except:
+ logger.debug(resource_info)
response = resource_info['default_mask']['admin']
if 'edit-admins' in response:
@@ -124,4 +125,4 @@ def check_owner_or_admin(dataset=None, trait_id=None, resource_id=None):
else:
return check_admin(resource_id)
- return "not-admin" \ No newline at end of file
+ return "not-admin"