Skip to content

Commit

Permalink
Flatten the list of columns given to create_index
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Sadauskas committed Sep 29, 2008
1 parent 156dc7c commit 63ebf04
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion dm-migrations/lib/migration.rb
Expand Up @@ -104,7 +104,7 @@ def create_index(table_name, *columns_and_options)
else
opts = {}
end
columns = columns_and_options
columns = columns_and_options.flatten

opts[:name] ||= "#{opts[:unique] ? 'unique_' : ''}index_#{table_name}_#{columns.join('_')}"

Expand Down

0 comments on commit 63ebf04

Please sign in to comment.