Skip to content

Commit

Permalink
Fix dereferencing remote statuses not using the correct account
Browse files Browse the repository at this point in the history
Follow-up to mastodon#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.
  • Loading branch information
ClearlyClaire committed Aug 24, 2020
1 parent a3ec9af commit f02edeb
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions app/lib/activitypub/activity.rb
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,8 @@ def dereference_object!
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

Expand Down

0 comments on commit f02edeb

Please sign in to comment.