Fix error when processing Add activity where the target is embedded and not a special collection (#38282)

This commit is contained in:
Claire
2026-03-19 09:13:50 +01:00
committed by GitHub
parent db074fc3e2
commit d9dbe62417

View File

@@ -17,7 +17,7 @@ class ActivityPub::Activity::Add < ActivityPub::Activity
add_collection
else
@collection = @account.collections.find_by(uri: @json['target'])
@collection = @account.collections.find_by(uri: value_or_id(@json['target']))
add_collection_item if @collection && Mastodon::Feature.collections_federation_enabled?
end
end