[#534] Updating external instances reachability on incoming federation.

This commit is contained in:
Ivan Tashkinov 2019-01-24 17:37:23 +03:00
commit 8654a591f0
9 changed files with 49 additions and 7 deletions

View file

@ -15,6 +15,8 @@ defmodule Pleroma.Web.OStatus.OStatusController do
alias Pleroma.Web.ActivityPub.ActivityPub
plug(Pleroma.Web.FederatingPlug when action in [:salmon_incoming])
plug(:set_requester_reachable when action in [:salmon_incoming])
action_fallback(:errors)
def feed_redirect(conn, %{"nickname" => nickname}) do
@ -201,4 +203,9 @@ defmodule Pleroma.Web.OStatus.OStatusController do
|> put_status(500)
|> text("Something went wrong")
end
defp set_requester_reachable(conn, _) do
Pleroma.Web.ControllerHelper.set_requester_reachable(conn)
conn
end
end