mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
passing unique parameter to belongs_to wrongly
passing `unique` parameter to belongs_to not right,
This commit is contained in:
parent
fd8da71118
commit
8b4e39b13d
1 changed files with 1 additions and 1 deletions
|
@ -154,7 +154,7 @@ case, the column definition might look like this:
|
|||
|
||||
```ruby
|
||||
create_table :accounts do |t|
|
||||
t.belongs_to :supplier, index: true, unique: true, foreign_key: true
|
||||
t.belongs_to :supplier, index: { unique: true }, foreign_key: true
|
||||
# ...
|
||||
end
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue