diff --git a/lib/paperclip/schema.rb b/lib/paperclip/schema.rb index 40872d123..d1cd07af0 100644 --- a/lib/paperclip/schema.rb +++ b/lib/paperclip/schema.rb @@ -24,7 +24,7 @@ def add_attachment(table_name, *attachment_names) attachment_names.each do |attachment_name| COLUMNS.each_pair do |column_name, column_type| column_options = options.merge(options[column_name.to_sym] || {}) - add_column(table_name, "#{attachment_name}_#{column_name}", column_type, column_options) + add_column(table_name, "#{attachment_name}_#{column_name}", column_type, *column_options) end end end @@ -51,7 +51,7 @@ def attachment(*attachment_names) attachment_names.each do |attachment_name| COLUMNS.each_pair do |column_name, column_type| column_options = options.merge(options[column_name.to_sym] || {}) - column("#{attachment_name}_#{column_name}", column_type, column_options) + column("#{attachment_name}_#{column_name}", column_type, *column_options) end end end