diff --git a/rails/add-a-reference-column-with-an-index.md b/rails/add-a-reference-column-with-an-index.md index 7322010..38e7f7d 100644 --- a/rails/add-a-reference-column-with-an-index.md +++ b/rails/add-a-reference-column-with-an-index.md @@ -8,7 +8,7 @@ which allows you to specify whether or not an index is to be added. ```ruby def up - add_reference :books, :authors, index: true + add_reference :books, :author, index: true end ``` @@ -19,7 +19,7 @@ using `uuid`s for all your primary keys. ```ruby def up - add_reference :books, :authors, type: :uuid, index: true + add_reference :books, :author, type: :uuid, index: true end ```