Skip to content

Commit

Permalink
Align spacing style of get_column_list function
Browse files Browse the repository at this point in the history
  • Loading branch information
guerler committed Aug 1, 2016
1 parent 4d6754f commit 15aba09
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions lib/galaxy/tools/parameters/basic.py
Original file line number Diff line number Diff line change
Expand Up @@ -1187,21 +1187,17 @@ def get_column_list( self, trans, other_values ):
"""
# Get the value of the associated data reference (a dataset)
dataset = other_values.get( self.data_ref, None )

# Check if a dataset is selected
if not dataset:
return []

column_list = None
for dataset in util.listify( dataset ):
# Use representative dataset if a dataset collection is parsed
if isinstance( dataset, trans.app.model.HistoryDatasetCollectionAssociation ):
dataset = dataset.to_hda_representative()

# Columns can only be identified if metadata is available
if not hasattr( dataset, 'metadata' ) or not hasattr( dataset.metadata, 'columns' ) or not dataset.metadata.columns:
return []

# Build up possible columns for this dataset
this_column_list = []
if self.numerical:
Expand All @@ -1212,7 +1208,6 @@ def get_column_list( self, trans, other_values ):
else:
for i in range( 0, dataset.metadata.columns ):
this_column_list.append( str( i + 1 ) )

# Take the intersection of these columns with the other columns.
if column_list is None:
column_list = this_column_list
Expand Down

0 comments on commit 15aba09

Please sign in to comment.