mirror of
https://github.com/mastodon/mastodon
synced 2024-11-24 15:16:19 +09:00
Avoid unnecessarily fetching the replies collection when it is empty (#10201)
This commit is contained in:
parent
dfb45374d2
commit
34f261e6af
@ -253,7 +253,7 @@ class ActivityPub::Activity::Create < ActivityPub::Activity
|
||||
collection = @object['replies']
|
||||
return if collection.nil?
|
||||
replies = ActivityPub::FetchRepliesService.new.call(status, collection, false)
|
||||
return if replies.present?
|
||||
return unless replies.nil?
|
||||
uri = value_or_id(collection)
|
||||
ActivityPub::FetchRepliesWorker.perform_async(status.id, uri) unless uri.nil?
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user