lib/ridgepole/dsl_parser.rb in ridgepole-1.2.0 vs lib/ridgepole/dsl_parser.rb in ridgepole-1.2.1
- old
+ new
@@ -38,12 +38,12 @@
fk_index = foreign_key_attrs[:options][:column] || "#{foreign_key_attrs[:to_table].singularize}_id"
next if attrs[:indices]&.any? { |_k, v| v[:column_name].first == fk_index }
# NOTE: For composite primary keys, the first column of the primary key is used as the foreign key index
next if Array(attrs[:options][:primary_key]).first == fk_index
- raise("The column `#{fk_index}` of the table `#{table_name}` has a foreign key but no index." \
- ' Although InnoDB creates an index automatically,' \
- ' please add one explicitly in order for ridgepole to manage it.')
+ raise("The column `#{fk_index}` of the table `#{table_name}` has a foreign key but no index. " \
+ 'Although InnoDB creates an index automatically, ' \
+ 'please add one explicitly in order for ridgepole to manage it.')
end
end
end
end