mirror of
https://github.com/lunaisnotaboy/mastodon.git
synced 2024-12-22 13:17:13 +00:00
When fetching an ActivityPub-enabled status, do not re-request it as text/html (#6196)
This commit is contained in:
parent
95bd85d9e8
commit
a594139115
|
@ -46,6 +46,8 @@ class FetchAtomService < BaseService
|
||||||
json = body_to_json(@response.to_s)
|
json = body_to_json(@response.to_s)
|
||||||
if supported_context?(json) && json['type'] == 'Person' && json['inbox'].present?
|
if supported_context?(json) && json['type'] == 'Person' && json['inbox'].present?
|
||||||
[json['id'], { prefetched_body: @response.to_s, id: true }, :activitypub]
|
[json['id'], { prefetched_body: @response.to_s, id: true }, :activitypub]
|
||||||
|
elsif supported_context?(json) && json['type'] == 'Note'
|
||||||
|
[json['id'], { prefetched_body: @response.to_s, id: true }, :activitypub]
|
||||||
else
|
else
|
||||||
@unsupported_activity = true
|
@unsupported_activity = true
|
||||||
nil
|
nil
|
||||||
|
|
Loading…
Reference in a new issue