Skip to content

Commit

Permalink
Underscore in _attr_readonly method name is back (Upgrading RoR guide…
Browse files Browse the repository at this point in the history
…) [ci skip]
  • Loading branch information
Aldo "xoen" Giambelluca committed Sep 2, 2012
1 parent 70d2d2c commit c38fe90
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion guides/source/upgrading_ruby_on_rails.textile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ The <tt>delete</tt> method in collection associations can now receive <tt>Fixnum

Rails 4.0 has changed how orders get stacked in +ActiveRecord::Relation+. In previous versions of rails new order was applied after previous defined order. But this is no long true. Check "ActiveRecord Query guide":active_record_querying.html#ordering for more information.

Rails 4.0 has changed <tt>serialized_attributes</tt> and <tt>attr_readonly</tt> to class methods only. Now you shouldn't use instance methods, it's deprecated. You must change them, e.g. <tt>self.serialized_attributes</tt> to <tt>self.class.serialized_attributes</tt>.
Rails 4.0 has changed <tt>serialized_attributes</tt> and <tt>&#95;attr_readonly</tt> to class methods only. Now you shouldn't use instance methods, it's deprecated. You must change them, e.g. <tt>self.serialized_attributes</tt> to <tt>self.class.serialized_attributes</tt>.

h4(#active_model4_0). Active Model

Expand Down

0 comments on commit c38fe90

Please sign in to comment.