Skip to content
This repository has been archived by the owner on Dec 12, 2021. It is now read-only.

Commit

Permalink
Merge pull request #302 from sunny/patch-1
Browse files Browse the repository at this point in the history
Strong parameter ends with "_attributes" in README.md
  • Loading branch information
lest committed Dec 1, 2013
2 parents 30cfe18 + 24ecbcb commit 1b0689d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ if the object is marked for destruction.
For Rails 4 or people using the "strong_parameters" gem, here is an example:

```ruby
params.require(:project).permit(:name, tasks: [:id, :name, :_destroy])
params.require(:project).permit(:name, tasks_attributes: [:id, :name, :_destroy])
```

The `:id` is to make sure you do not end up with a whole lot of tasks.
Expand Down

0 comments on commit 1b0689d

Please sign in to comment.