Skip to content

Commit e92187c

Browse files
authored
Merge pull request #959 from hubmapconsortium/shirey/update-globus-url-endpoint
Shirey/update globus url endpoint
2 parents 5259e56 + 98d885c commit e92187c

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.6.7
1+
2.6.8

src/app.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2841,7 +2841,8 @@ def get_globus_url(id):
28412841

28422842
# The user is in the Globus group with full access to thie dataset,
28432843
# so they have protected level access to it
2844-
if ('hmgroupids' in user_info) and (group_uuid in user_info['hmgroupids']):
2844+
protected_group_uuid = auth_helper_instance.get_protected_data_group_uuid()
2845+
if 'hmgroupids' in user_info and (group_uuid in user_info['hmgroupids'] or (not protected_group_uuid is None and protected_group_uuid in user_info['hmgroupids'])):
28452846
user_data_access_level = ACCESS_LEVEL_PROTECTED
28462847
else:
28472848
if not 'data_access_level' in user_info:
@@ -2875,6 +2876,10 @@ def get_globus_url(id):
28752876
globus_server_uuid = app.config['GLOBUS_PROTECTED_ENDPOINT_UUID']
28762877
access_dir = access_level_prefix_dir(app.config['PROTECTED_DATA_SUBDIR'])
28772878
dir_path = dir_path + access_dir + group_name + "/"
2879+
elif (entity_data_access_level == ACCESS_LEVEL_PROTECTED) and (entity_dict['status'] == 'Published'):
2880+
globus_server_uuid = app.config['GLOBUS_PUBLIC_ENDPOINT_UUID']
2881+
access_dir = access_level_prefix_dir(app.config['PUBLIC_DATA_SUBDIR'])
2882+
dir_path = dir_path + access_dir + "/"
28782883

28792884
if globus_server_uuid is None:
28802885
forbidden_error("Access not granted")

0 commit comments

Comments
 (0)