We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 2744bdcd authored by mattl's avatar mattl

Empty resource would throw exception

The "+ Remote" link on your profile page broke because of exception.
parent 57f78dc6
......@@ -242,7 +242,11 @@ class OStatusSubAction extends Action
function pullRemoteProfile()
$validate = new Validate();
$this->profile_uri = Discovery::normalize($this->trimmed('profile'));
try {
$this->profile_uri = Discovery::normalize($this->trimmed('profile'));
} catch (Exception $e) {
$this->profile_uri = null;
try {
if (Discovery::isAcct($this->profile_uri) && $validate->email(mb_substr($this->profile_uri, 5))) {
$this->oprofile = Ostatus_profile::ensureWebfinger($this->profile_uri);
Markdown is supported
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