From ff0d9b93b9074c479dd6de657c71812f0ac40cbe Mon Sep 17 00:00:00 2001 From: Dave Desrochers Date: Tue, 28 Feb 2012 10:20:27 -0800 Subject: reset_counters() was crashing when there were multiple belongs_to associations with the same foreign key. This closes #5200. --- activerecord/CHANGELOG.md | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'activerecord/CHANGELOG.md') diff --git a/activerecord/CHANGELOG.md b/activerecord/CHANGELOG.md index da31da3269..c5ef39b9d2 100644 --- a/activerecord/CHANGELOG.md +++ b/activerecord/CHANGELOG.md @@ -1,5 +1,11 @@ ## Rails 4.0.0 (unreleased) ## +* Fix `reset_counters` when there are multiple `belongs_to` association with the + same foreign key and one of them have a counter cache. + Fixes #5200. + + *Dave Desrochers* + * `serialized_attributes` and `_attr_readonly` become class method only. Instance reader methods are deprecated. *kennyj* -- cgit v1.2.3