aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/rails/generators/active_record/migration/migration_generator.rb
diff options
context:
space:
mode:
Diffstat (limited to 'activerecord/lib/rails/generators/active_record/migration/migration_generator.rb')
-rw-r--r--activerecord/lib/rails/generators/active_record/migration/migration_generator.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/activerecord/lib/rails/generators/active_record/migration/migration_generator.rb b/activerecord/lib/rails/generators/active_record/migration/migration_generator.rb
index 1de2aff632..8511531af7 100644
--- a/activerecord/lib/rails/generators/active_record/migration/migration_generator.rb
+++ b/activerecord/lib/rails/generators/active_record/migration/migration_generator.rb
@@ -23,7 +23,7 @@ module ActiveRecord
# Sets the default migration template that is being used for the generation of the migration.
# Depending on command line arguments, the migration template and the table name instance
# variables are set up.
- def set_local_assigns! # :doc:
+ def set_local_assigns!
@migration_template = "migration.rb"
case file_name
when /^(add|remove)_.*_(?:to|from)_(.*)/
@@ -42,13 +42,13 @@ module ActiveRecord
end
end
- def set_index_names # :doc:
+ def set_index_names
attributes.each_with_index do |attr, i|
attr.index_name = [attr, attributes[i - 1]].map { |a| index_name_for(a) }
end
end
- def index_name_for(attribute) # :doc:
+ def index_name_for(attribute)
if attribute.foreign_key?
attribute.name
else