Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #357 from rafaelgoulart/master

syntax highlight about Rails 4 strong parameters notation in README
  • Loading branch information...
commit 68dd475af291bb4bab378d43193411f9f053f10a 2 parents c302307 + 94930cd
@rafaelfranca rafaelfranca authored
Showing with 5 additions and 3 deletions.
  1. +5 −3
@@ -711,9 +711,11 @@ end
Instead you can stick to a standard Rails 4 notation (as rails scaffold generates) and write:
- def widget_params
- params.require(:widget).permit(:permitted_field, :other_permitted_field)
- end
+def widget_params
+ params.require(:widget).permit(:permitted_field, :other_permitted_field)
In such case you should remove #permitted_params method because it has greater priority.
Please sign in to comment.
Something went wrong with that request. Please try again.