diff options
author | Sebastian Martinez <sebastian@wyeworks.com> | 2011-03-27 18:52:21 -0300 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2011-03-27 18:55:30 -0300 |
commit | 0e1fed537a7699a7ded02f77b71d222d7207c5ad (patch) | |
tree | a6d0acc8b1198593c3ca830755cbb643140de7d2 /activerecord/lib/active_record/associations/has_one_association.rb | |
parent | eea6a65488e3f590d4d9cd922f54febb151799ad (diff) | |
download | rails-0e1fed537a7699a7ded02f77b71d222d7207c5ad.tar.gz rails-0e1fed537a7699a7ded02f77b71d222d7207c5ad.tar.bz2 rails-0e1fed537a7699a7ded02f77b71d222d7207c5ad.zip |
Revert "Removed #update_attribute method. New #update_column method."
This reverts commit 45c233ef819dc7b67e259dd73f24721fec28b8c8.
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
Diffstat (limited to 'activerecord/lib/active_record/associations/has_one_association.rb')
-rw-r--r-- | activerecord/lib/active_record/associations/has_one_association.rb | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/activerecord/lib/active_record/associations/has_one_association.rb b/activerecord/lib/active_record/associations/has_one_association.rb index dfcb116392..1d2e8667e4 100644 --- a/activerecord/lib/active_record/associations/has_one_association.rb +++ b/activerecord/lib/active_record/associations/has_one_association.rb @@ -34,8 +34,7 @@ module ActiveRecord when :destroy target.destroy when :nullify - target.send("#{reflection.foreign_key}=", nil) - target.save(:validations => false) + target.update_attribute(reflection.foreign_key, nil) end end end |