X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FModel%2FGServer.php;h=f68851af6826b945cdc25f392a7381a5636c7db8;hb=feb74b4d9aeecbcac2b81cd6f0e0c8cfde1464f3;hp=e93c347627d5bd269f2b6a72418c71a50ab95acc;hpb=c60464a4bea0c43363793d3cc2d7703314816df8;p=friendica.git diff --git a/src/Model/GServer.php b/src/Model/GServer.php index e93c347627..f68851af68 100644 --- a/src/Model/GServer.php +++ b/src/Model/GServer.php @@ -177,9 +177,13 @@ class GServer public static function reachable(string $profile, string $server = '', string $network = '', bool $force = false): bool { if ($server == '') { - $contact = Contact::getByURL($profile, null, ['baseurl']); + $contact = Contact::getByURL($profile, null, ['baseurl', 'network']); if (!empty($contact['baseurl'])) { $server = $contact['baseurl']; + } elseif ($contact['network'] == Protocol::DIASPORA) { + $parts = parse_url($profile); + unset($parts['path']); + $server = (string)Uri::fromParts($parts); } }