Skip to content

Commit

Permalink
Merge pull request #5943 from erasche/fix-ftp-composite-upload
Browse files Browse the repository at this point in the history
[18.01] Correct access for FTP files in composite datatype
  • Loading branch information
martenson committed Apr 24, 2018
2 parents 9f8021f + a5c75d2 commit 88bf6bb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/galaxy/tools/parameters/grouping.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,10 @@ def get_composite_dataset_name(self, context):
if dataset_name is None:
filenames = list()
for composite_file in context.get('files', []):
filenames.append(composite_file.get('file_data', {}).get('filename', ''))
if not composite_file.get('ftp_files', ''):
filenames.append(composite_file.get('file_data', {}).get('filename', ''))
else:
filenames.append(composite_file.get('ftp_files', [])[0])
dataset_name = os.path.commonprefix(filenames).rstrip('.') or None
if dataset_name is None:
dataset_name = 'Uploaded Composite Dataset (%s)' % self.get_file_type(context)
Expand Down

0 comments on commit 88bf6bb

Please sign in to comment.