Merge branch 'bugfix/webfinger-xml-crash' into 'develop'
webfinger robustness improvements See merge request pleroma/pleroma!195
This commit is contained in:
commit
0a0c6bf394
3 changed files with 8 additions and 4 deletions
|
|
@ -253,7 +253,7 @@ defmodule Pleroma.Web.WebFinger do
|
|||
String.replace(template, "{uri}", URI.encode(account))
|
||||
|
||||
_ ->
|
||||
"http://#{domain}/.well-known/webfinger?resource=acct:#{account}"
|
||||
"https://#{domain}/.well-known/webfinger?resource=acct:#{account}"
|
||||
end
|
||||
|
||||
with response <-
|
||||
|
|
|
|||
|
|
@ -32,6 +32,10 @@ defmodule Pleroma.Web.XML do
|
|||
:exit, _error ->
|
||||
Logger.debug("Couldn't parse XML: #{inspect(text)}")
|
||||
:error
|
||||
rescue
|
||||
e ->
|
||||
Logger.debug("Couldn't parse XML: #{inspect(text)}")
|
||||
:error
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue