Skip to content

Commit

Permalink
Mention the removal of attr_accessible and attr_protected in the upgr…
Browse files Browse the repository at this point in the history
…ading guide

Point to the Protected Attributes gem to those who want a smoothly
upgrade path before to change to use Strong Parameters.

[ci skip]
  • Loading branch information
rafaelfranca committed Feb 24, 2013
1 parent d5ec8ef commit d1c5f87
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions guides/source/upgrading_ruby_on_rails.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ Rails 4.0 no longer supports loading plugins from `vendor/plugins`. You must rep

* Rails 4.0 has changed `serialized_attributes` and `attr_readonly` to class methods only. Now you shouldn't use instance methods, it's deprecated. You must change them, e.g. `self.serialized_attributes` to `self.class.serialized_attributes`.

* Rails 4.0 has removed `attr_accessible` and `attr_protected` feature in favor of Strong Parameters. You can use the [Protected Attributes gem](https://github.com/rails/protected_attributes) to a smoothly upgrade path.

### Active Model

* Rails 4.0 has changed how errors attach with the `ActiveModel::Validations::ConfirmationValidator`. Now when confirmation validations fail the error will be attached to `:#{attribute}_confirmation` instead of `attribute`.
Expand Down

0 comments on commit d1c5f87

Please sign in to comment.