mirror of
https://git.pleroma.social/pleroma/pleroma.git
synced 2024-12-23 00:26:30 +00:00
Phoenix detects the webfinger requests with content-type application/jrd+json as "jrd" now
This commit is contained in:
parent
347e5f33c7
commit
1b5168ae02
2 changed files with 2 additions and 2 deletions
|
@ -182,7 +182,7 @@ defmodule Pleroma.Web.Router do
|
|||
end
|
||||
|
||||
pipeline :well_known do
|
||||
plug(:accepts, ["json", "jrd+json", "xml", "xrd+xml"])
|
||||
plug(:accepts, ["json", "jrd", "jrd+json", "xml", "xrd+xml"])
|
||||
end
|
||||
|
||||
pipeline :config do
|
||||
|
|
|
@ -30,7 +30,7 @@ defmodule Pleroma.Web.WebFinger.WebFingerController do
|
|||
end
|
||||
|
||||
def webfinger(%{assigns: %{format: format}} = conn, %{"resource" => resource})
|
||||
when format in ["json", "jrd+json"] do
|
||||
when format in ["jrd", "json", "jrd+json"] do
|
||||
with {:ok, response} <- WebFinger.webfinger(resource, "JSON") do
|
||||
json(conn, response)
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue