Skip to content
This repository has been archived by the owner on Aug 17, 2017. It is now read-only.

Commit

Permalink
Update Installation section of the README
Browse files Browse the repository at this point in the history
Mentions setting the config.active_record.whitelist_attributes property to false, allowing mass assignment to be used freely in code and tests.
  • Loading branch information
sudhirj committed Oct 20, 2012
1 parent 8ade825 commit 321fe69
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.rdoc
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,12 @@ every model you want protected.
include ActiveModel::ForbiddenAttributesProtection
end

If you want to now disable the default whitelisting that occurs in later versions of Rails, change the +config.active_record.whitelist_attributes+ property in your +config/application.rb+:

config.active_record.whitelist_attributes = false

This will allow you to remove / not have to use +attr_accessible+ and do mass assignment inside your code and tests.

== Compatibility

This plugin is only fully compatible with Rails versions 3.1 and 3.2 but not 4.0+, as it is part of Rails Core in 4.0.

0 comments on commit 321fe69

Please sign in to comment.