From 03bbc74d1bfbfd8177805d74d4984b41c302733e Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Tue, 4 Jun 2019 23:11:44 +0200 Subject: [PATCH] Change reblogs counter to be updated when boosted privately (#10964) --- app/models/status.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/status.rb b/app/models/status.rb index a7f32f41c78742..fb9bbc9a9a31be 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -499,7 +499,7 @@ def increment_counter_caches return if direct_visibility? account&.increment_count!(:statuses_count) - reblog&.increment_count!(:reblogs_count) if reblog? && (public_visibility? || unlisted_visibility?) + reblog&.increment_count!(:reblogs_count) if reblog? thread&.increment_count!(:replies_count) if in_reply_to_id.present? && (public_visibility? || unlisted_visibility?) end @@ -507,7 +507,7 @@ def decrement_counter_caches return if direct_visibility? || marked_for_mass_destruction? account&.decrement_count!(:statuses_count) - reblog&.decrement_count!(:reblogs_count) if reblog? && (public_visibility? || unlisted_visibility?) + reblog&.decrement_count!(:reblogs_count) if reblog? thread&.decrement_count!(:replies_count) if in_reply_to_id.present? && (public_visibility? || unlisted_visibility?) end