diff options
author | ThibG <thib@sitedethib.com> | 2018-08-22 21:35:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-08-22 21:35:07 +0200 |
commit | 8aa58e34bb2b62192a997ac7ea8919b22fc45f80 (patch) | |
tree | abc0ea9862c55c2e114c855b20eb4a35f1141709 /app/services/activitypub | |
parent | 628fca50e20bcf41f206877083fc5ee8789c1088 (diff) | |
parent | e70fc059a9511d43b42c2502514f6220b416cdd5 (diff) |
Merge pull request #665 from ThibG/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'app/services/activitypub')
-rw-r--r-- | app/services/activitypub/fetch_remote_account_service.rb | 2 | ||||
-rw-r--r-- | app/services/activitypub/fetch_remote_key_service.rb | 2 | ||||
-rw-r--r-- | app/services/activitypub/fetch_remote_status_service.rb | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/app/services/activitypub/fetch_remote_account_service.rb b/app/services/activitypub/fetch_remote_account_service.rb index 41fec9170..1ec9ee5dd 100644 --- a/app/services/activitypub/fetch_remote_account_service.rb +++ b/app/services/activitypub/fetch_remote_account_service.rb @@ -11,7 +11,7 @@ class ActivityPub::FetchRemoteAccountService < BaseService @json = if prefetched_body.nil? fetch_resource(uri, id) else - body_to_json(prefetched_body) + body_to_json(prefetched_body, compare_id: id ? uri : nil) end return if !supported_context? || !expected_type? || (break_on_redirect && @json['movedTo'].present?) diff --git a/app/services/activitypub/fetch_remote_key_service.rb b/app/services/activitypub/fetch_remote_key_service.rb index 505baccd4..df17d9079 100644 --- a/app/services/activitypub/fetch_remote_key_service.rb +++ b/app/services/activitypub/fetch_remote_key_service.rb @@ -17,7 +17,7 @@ class ActivityPub::FetchRemoteKeyService < BaseService @json = fetch_resource(uri, id) end else - @json = body_to_json(prefetched_body) + @json = body_to_json(prefetched_body, compare_id: id ? uri : nil) end return unless supported_context?(@json) && expected_type? diff --git a/app/services/activitypub/fetch_remote_status_service.rb b/app/services/activitypub/fetch_remote_status_service.rb index 2b447abb3..469821032 100644 --- a/app/services/activitypub/fetch_remote_status_service.rb +++ b/app/services/activitypub/fetch_remote_status_service.rb @@ -8,7 +8,7 @@ class ActivityPub::FetchRemoteStatusService < BaseService @json = if prefetched_body.nil? fetch_resource(uri, id, on_behalf_of) else - body_to_json(prefetched_body) + body_to_json(prefetched_body, compare_id: id ? uri : nil) end return unless supported_context? && expected_type? |