aboutsummaryrefslogtreecommitdiff
path: root/wqflask
diff options
context:
space:
mode:
authorzsloan2020-10-08 14:36:46 -0500
committerzsloan2020-10-08 14:36:46 -0500
commit02b7af0c4c44ec7e565e7c4bb66287ed86b432b2 (patch)
tree6e6295920de325ede18970376eae582286403233 /wqflask
parent46232706289575e1798442f3a763aaf1407ec6fa (diff)
parent5880b399efbc0175e726be5a61945c30a5fe6260 (diff)
downloadgenenetwork2-02b7af0c4c44ec7e565e7c4bb66287ed86b432b2.tar.gz
Merge branch 'testing' of github.com:genenetwork/genenetwork2 into testing
Diffstat (limited to 'wqflask')
-rw-r--r--wqflask/wqflask/resource_manager.py20
1 files changed, 10 insertions, 10 deletions
diff --git a/wqflask/wqflask/resource_manager.py b/wqflask/wqflask/resource_manager.py
index 39a07310..14ff2183 100644
--- a/wqflask/wqflask/resource_manager.py
+++ b/wqflask/wqflask/resource_manager.py
@@ -25,16 +25,16 @@ def manage_resource():
group_masks_with_names = get_group_names(group_masks)
default_mask = resource_info['default_mask']['data']
owner_id = resource_info['owner_id']
- owner_info = get_user_by_unique_column("user_id", owner_id)
-
- if 'name' in owner_info:
- owner_display_name = owner_info['full_name']
- elif 'user_name' in owner_info:
- owner_display_name = owner_info['user_name']
- elif 'email_address' in owner_info:
- owner_display_name = owner_info['email_address']
- else:
- owner_display_name = None
+
+ owner_display_name = None
+ if owner_id != "none":
+ owner_info = get_user_by_unique_column("user_id", owner_id)
+ if 'name' in owner_info:
+ owner_display_name = owner_info['full_name']
+ elif 'user_name' in owner_info:
+ owner_display_name = owner_info['user_name']
+ elif 'email_address' in owner_info:
+ owner_display_name = owner_info['email_address']
return render_template("admin/manage_resource.html", owner_name = owner_display_name, resource_id = resource_id, resource_info=resource_info, default_mask=default_mask, group_masks=group_masks_with_names, admin_status=admin_status)