diff options
-rw-r--r-- | app/models/status.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/status.rb b/app/models/status.rb index 7f4066036..50a558ed1 100644 --- a/app/models/status.rb +++ b/app/models/status.rb @@ -573,7 +573,7 @@ class Status < ApplicationRecord end if target_account.id != account&.id && target_account&.user&.max_history_public.present? - history_limit = account.following?(target_account) ? target_account.user.max_history_private : target_account.user.max_history_public + history_limit = account&.following?(target_account) ? target_account.user.max_history_private : target_account.user.max_history_public query = query.where('statuses.updated_at >= ?', history_limit.weeks.ago) if history_limit.positive? end |