aboutsummaryrefslogtreecommitdiff
path: root/lib/pleroma/web/websub/websub.ex
diff options
context:
space:
mode:
Diffstat (limited to 'lib/pleroma/web/websub/websub.ex')
-rw-r--r--lib/pleroma/web/websub/websub.ex15
1 files changed, 15 insertions, 0 deletions
diff --git a/lib/pleroma/web/websub/websub.ex b/lib/pleroma/web/websub/websub.ex
index 1fb993282..2ce6dcc19 100644
--- a/lib/pleroma/web/websub/websub.ex
+++ b/lib/pleroma/web/websub/websub.ex
@@ -7,6 +7,7 @@ defmodule Pleroma.Web.Websub do
alias Pleroma.Activity
alias Pleroma.Instances
alias Pleroma.Repo
+ alias Pleroma.User
alias Pleroma.Web.ActivityPub.Visibility
alias Pleroma.Web.Endpoint
alias Pleroma.Web.Federator
@@ -313,4 +314,18 @@ defmodule Pleroma.Web.Websub do
{:error, response}
end
end
+
+ def gather_webfinger_links(%User{} = user) do
+ [
+ %{
+ "rel" => "http://schemas.google.com/g/2010#updates-from",
+ "type" => "application/atom+xml",
+ "href" => OStatus.feed_path(user)
+ },
+ %{
+ "rel" => "http://ostatus.org/schema/1.0/subscribe",
+ "template" => OStatus.remote_follow_path()
+ }
+ ]
+ end
end