From 6ad0ddebe4be9fb76b9119924674b4679e8da74a Mon Sep 17 00:00:00 2001 From: Claire Date: Tue, 26 Aug 2025 17:51:56 +0200 Subject: [PATCH] Fix quotes counting (#35917) --- app/models/quote.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/models/quote.rb b/app/models/quote.rb index ad5c9509ea1..dcfcd3b353c 100644 --- a/app/models/quote.rb +++ b/app/models/quote.rb @@ -90,13 +90,13 @@ class Quote < ApplicationRecord end def increment_counter_caches! - return unless acceptable? + return unless accepted? quoted_status&.increment_count!(:quotes_count) end def decrement_counter_caches! - return unless acceptable? + return unless accepted? quoted_status&.decrement_count!(:quotes_count) end @@ -104,7 +104,7 @@ class Quote < ApplicationRecord def update_counter_caches! return if legacy? || !state_previously_changed? - if acceptable? + if accepted? quoted_status&.increment_count!(:quotes_count) else # TODO: are there cases where this would not be correct?