about summary refs log tree commit diff
path: root/app/services/activitypub/fetch_remote_status_service.rb
diff options
context:
space:
mode:
authorClaire <claire.github-309c@sitedethib.com>2022-05-17 14:52:26 +0200
committerGitHub <noreply@github.com>2022-05-17 14:52:26 +0200
commite0bdaeab657d9a320aaf506d98ca82d41e7bfdd5 (patch)
treeb53a50b162b46b1e9179bf2e49299a452544d115 /app/services/activitypub/fetch_remote_status_service.rb
parentc78a622ba4bd7fce511e5f079dd6b8deb17f9cef (diff)
Fix NoMethodError when resolving a link that redirects to a local post (#18314)
* Fix NoMethodError when resolving a link that redirects to a local post

* Fix tests
Diffstat (limited to 'app/services/activitypub/fetch_remote_status_service.rb')
-rw-r--r--app/services/activitypub/fetch_remote_status_service.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/app/services/activitypub/fetch_remote_status_service.rb b/app/services/activitypub/fetch_remote_status_service.rb
index 9672b3d2b..803098245 100644
--- a/app/services/activitypub/fetch_remote_status_service.rb
+++ b/app/services/activitypub/fetch_remote_status_service.rb
@@ -30,6 +30,7 @@ class ActivityPub::FetchRemoteStatusService < BaseService
     end
 
     return if activity_json.nil? || object_uri.nil? || !trustworthy_attribution?(@json['id'], actor_uri)
+    return ActivityPub::TagManager.instance.uri_to_resource(object_uri, Status) if ActivityPub::TagManager.instance.local_uri?(object_uri)
 
     actor = account_from_uri(actor_uri)