Merge branch 'feature/1728-webfinger-acct-scheme' into 'develop'
Webfinger: Request account info with the acct scheme Closes #1728 See merge request pleroma/pleroma!2465
This commit is contained in:
commit
f84c8f2f0d
3 changed files with 12 additions and 9 deletions
|
|
@ -161,13 +161,15 @@ defmodule Pleroma.Web.WebFinger do
|
|||
URI.parse(account).host
|
||||
end
|
||||
|
||||
encoded_account = URI.encode("acct:#{account}")
|
||||
|
||||
address =
|
||||
case find_lrdd_template(domain) do
|
||||
{:ok, template} ->
|
||||
String.replace(template, "{uri}", URI.encode(account))
|
||||
String.replace(template, "{uri}", encoded_account)
|
||||
|
||||
_ ->
|
||||
"https://#{domain}/.well-known/webfinger?resource=acct:#{account}"
|
||||
"https://#{domain}/.well-known/webfinger?resource=#{encoded_account}"
|
||||
end
|
||||
|
||||
with response <-
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue