diff options
author | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-08-15 11:28:22 -0300 |
---|---|---|
committer | Rafael Mendonça França <rafaelmfranca@gmail.com> | 2012-08-15 11:58:41 -0300 |
commit | 8055cd65688d5aee9bf756c8483f2c30f75d06cc (patch) | |
tree | c7956934bb7672074e6a06c6f0611530ee5507df /activerecord/lib/active_record/associations | |
parent | 786713a3abc375fab4d5c2f6f62a878c2ab51022 (diff) | |
download | rails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.tar.gz rails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.tar.bz2 rails-8055cd65688d5aee9bf756c8483f2c30f75d06cc.zip |
Do not use update_column where update_attribute is not interchangeable
Revert "Deprecate update_attribute."
This reverts commit b081f6b59fb3f15d12043072ad9b331ffd2bc56e.
Reason: Since the new deprecation policy we removed the deprecation of
update_attribute but we didn't reverted the changes to use
update_column.
Fixes #7306
Diffstat (limited to 'activerecord/lib/active_record/associations')
-rw-r--r-- | activerecord/lib/active_record/associations/has_one_association.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/associations/has_one_association.rb b/activerecord/lib/active_record/associations/has_one_association.rb index 08f66eed3f..501ebe7c5b 100644 --- a/activerecord/lib/active_record/associations/has_one_association.rb +++ b/activerecord/lib/active_record/associations/has_one_association.rb @@ -38,7 +38,7 @@ module ActiveRecord when :destroy target.destroy when :nullify - target.update_column(reflection.foreign_key, nil) + target.update_attribute(reflection.foreign_key, nil) end end end |