Fix counter_cache double increment bug#24713
Fix counter_cache double increment bug#24713sgrif merged 1 commit intorails:masterfrom tomkadwill:fix_counter_cache_increment
Conversation
|
(@rails-bot has picked a reviewer for you, use r? to override) |
There was a problem hiding this comment.
While we don't accept PR's to change hash syntax only, new tests and code should use the new hash syntax Topic.create(title: 'Zoom-zoom-zoom)
There was a problem hiding this comment.
Thanks @eileencodes, I've updated the PR to fix the hash syntax
|
My PR is failing on Travis but it looks like Rails is currently red, is that correct? The failures seem unrelated to my change. Sorry if this is a silly question, I am a new contributor :). cc/ @eileencodes @vipulnsward @rafaelfranca |
|
Please don't explicitly ping contributors who aren't assigned without specific reason in the future |
|
What version of Rails would this have been fixed in? I'm running 5.0.0.1 and I'm running into either this issue or a very similar one |
|
@adambedford As you can see here, this fix is present from 5.0 onwards. So bug you are facing may be different |
Summary
Fixes counter cache bug, reported in #24183. Counter cache is incrementing twice when replacing the association.
Other Information