From d6e7e88afbffbb3003e275a1f0d26cdf5bdaff1d Mon Sep 17 00:00:00 2001 From: Jonny Saunders Date: Mon, 28 Oct 2024 09:36:04 -0700 Subject: [PATCH] Update app/services/activitypub/fetch_all_replies_service.rb Co-authored-by: Claire --- app/services/activitypub/fetch_all_replies_service.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/services/activitypub/fetch_all_replies_service.rb b/app/services/activitypub/fetch_all_replies_service.rb index 50be4c9e8b..1c17ba4732 100644 --- a/app/services/activitypub/fetch_all_replies_service.rb +++ b/app/services/activitypub/fetch_all_replies_service.rb @@ -41,7 +41,7 @@ class ActivityPub::FetchAllRepliesService < ActivityPub::FetchRepliesService Status.where(uri: uris).should_fetch_replies.touch_all(:fetched_replies_at) # Reject all statuses that we already have in the db - uris = uris.reject { |uri| dont_update.include?(uri) }.take(MAX_REPLIES) + uris = (uris - dont_update).take(MAX_REPLIES) Rails.logger.debug { "FetchAllRepliesService - #{@collection_or_uri}: Fetching filtered statuses: #{uris}" } uris