mirror of
https://framagit.org/framasoft/mobilizon.git
synced 2024-12-22 07:52:43 +00:00
fix(nodeinfo): fix getting application actor information from NodeInfo response
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
707add36dd
commit
dd775b6ae2
1 changed files with 3 additions and 2 deletions
|
@ -25,9 +25,10 @@ defmodule Mobilizon.Federation.NodeInfo do
|
|||
|
||||
defp extract_application_actor(body) do
|
||||
body
|
||||
|> Enum.find(%{rel: @application_uri, href: nil}, fn %{rel: rel, href: href} ->
|
||||
|> Map.get("links", [])
|
||||
|> Enum.find(%{"rel" => @application_uri, "href" => nil}, fn %{"rel" => rel, "href" => href} ->
|
||||
rel == @application_uri and is_binary(href)
|
||||
end)
|
||||
|> Map.get(:href)
|
||||
|> Map.get("href")
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue