1
0
mirror of https://github.com/funamitech/mastodon synced 2024-11-28 06:48:45 +09:00

Fix dereferencing remote statuses not using the correct account (#14656)

Follow-up to #14359

In the case of limited toots, the receiver may not be explicitly part of the
audience. If a specific user's inbox URI was specified, it makes sense to
dereference the toot from the corresponding user, instead of trying to find
someone in the explicit audience.
This commit is contained in:
ThibG 2020-08-24 16:56:21 +02:00 committed by GitHub
parent e8d41bc2fe
commit 92319d7340
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -168,6 +168,8 @@ class ActivityPub::Activity
end
def signed_fetch_account
return Account.find(@options[:delivered_to_account_id]) if @options[:delivered_to_account_id].present?
first_mentioned_local_account || first_local_follower
end