Operations that allow for mass assignment (setting multiple attributes of an object using a hash), such as ActiveRecord::Base.new
, should take care not to
- allow arbitrary parameters to be set by the user. Otherwise, unintended attributes may be set, such as an isAdmin
feild for a User
object.
+ allow arbitrary parameters to be set by the user. Otherwise, unintended attributes may be set, such as an is_admin
field for a User
object.