diff options
author | Amparo Luna + Guillermo Iguaran <amparo.m.luna@gmail.com+guilleiguaran@gmail.com> | 2013-01-02 16:16:24 -0500 |
---|---|---|
committer | Amparo Luna + Guillermo Iguaran <amparo.m.luna@gmail.com+guilleiguaran@gmail.com> | 2013-01-03 12:03:34 -0500 |
commit | 1bb020063c1bad6cc6a2ad7a4635bfc31a308f65 (patch) | |
tree | 1559ce4b520e4134ad2ea52a1f6e20f3581aa300 /activerecord/lib | |
parent | 1f3a1fedf951dbc4b72d178e2a649c4afd2f1566 (diff) | |
download | rails-1bb020063c1bad6cc6a2ad7a4635bfc31a308f65.tar.gz rails-1bb020063c1bad6cc6a2ad7a4635bfc31a308f65.tar.bz2 rails-1bb020063c1bad6cc6a2ad7a4635bfc31a308f65.zip |
Change docs to use update instead of update_attributes
Diffstat (limited to 'activerecord/lib')
-rw-r--r-- | activerecord/lib/active_record/nested_attributes.rb | 2 | ||||
-rw-r--r-- | activerecord/lib/active_record/persistence.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/nested_attributes.rb b/activerecord/lib/active_record/nested_attributes.rb index 4c9bd76d7c..c5bd11edbf 100644 --- a/activerecord/lib/active_record/nested_attributes.rb +++ b/activerecord/lib/active_record/nested_attributes.rb @@ -58,7 +58,7 @@ module ActiveRecord # It also allows you to update the avatar through the member: # # params = { member: { avatar_attributes: { id: '2', icon: 'sad' } } } - # member.update_attributes params[:member] + # member.update params[:member] # member.avatar.icon # => 'sad' # # By default you will only be able to set and update attributes on the diff --git a/activerecord/lib/active_record/persistence.rb b/activerecord/lib/active_record/persistence.rb index 287c42a481..3011f959a5 100644 --- a/activerecord/lib/active_record/persistence.rb +++ b/activerecord/lib/active_record/persistence.rb @@ -223,7 +223,7 @@ module ActiveRecord alias update_attributes update - # Updates its receiver just like +update_attributes+ but calls <tt>save!</tt> instead + # Updates its receiver just like +update+ but calls <tt>save!</tt> instead # of +save+, so an exception is raised if the record is invalid. def update!(attributes) # The following transaction covers any possible database side-effects of the |