webfinger: expose the application/ld+json link alongside the older application/activi...
authorWilliam Pitcock <nenolod@dereferenced.org>
Sat, 19 May 2018 05:43:13 +0000 (05:43 +0000)
committerWilliam Pitcock <nenolod@dereferenced.org>
Sat, 19 May 2018 06:28:03 +0000 (01:28 -0500)
lib/pleroma/web/web_finger/web_finger.ex

index 6ffa80a43b6e0ed7cb8e5ce44a693f370a07f4c8..241dfb4c8f84bfca356dccdf28d046d8bb332397 100644 (file)
@@ -86,6 +86,7 @@ defmodule Pleroma.Web.WebFinger do
           "href" => "data:application/magic-public-key,#{magic_key}"
         },
         %{"rel" => "self", "type" => "application/activity+json", "href" => user.ap_id},
+        %{"rel" => "self", "type" => "application/ld+json; profile=\"https://www.w3.org/ns/activitystreams\"", "href" => user.ap_id},
         %{
           "rel" => "http://ostatus.org/schema/1.0/subscribe",
           "template" => OStatus.remote_follow_path()
@@ -117,6 +118,7 @@ defmodule Pleroma.Web.WebFinger do
         {:Link,
          %{rel: "magic-public-key", href: "data:application/magic-public-key,#{magic_key}"}},
         {:Link, %{rel: "self", type: "application/activity+json", href: user.ap_id}},
+        {:Link, %{rel: "self", type: "application/ld+json; profile=&quot;https://www.w3.org/ns/activitystreams&quot;", href: user.ap_id}},
         {:Link,
          %{rel: "http://ostatus.org/schema/1.0/subscribe", template: OStatus.remote_follow_path()}}
       ]