Commit 1b480e35 authored by kaniini's avatar kaniini
Browse files

user: add helper for fetching profile url (which may be different than ap id)

parent a8137159
......@@ -42,6 +42,10 @@ def banner_url(user) do
def profile_url(%User{info: %{"source_data" => %{"url" => url}}}), do: url
def profile_url(%User{ap_id: ap_id}), do: ap_id
def profile_url(_), do: nil
def ap_id(%User{nickname: nickname}) do
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment