Skip to content

Commit ded004c

Browse files
committed
primary_key opt for add_foreign_key should be a symbol too
1 parent d45c3ab commit ded004c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ def foreign_keys(table_name)
705705
#
706706
# ====== Creating a foreign key on a specific column
707707
#
708-
# add_foreign_key :articles, :users, column: :author_id, primary_key: "lng_id"
708+
# add_foreign_key :articles, :users, column: :author_id, primary_key: :lng_id
709709
#
710710
# generates:
711711
#

0 commit comments

Comments
 (0)