X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=src%2FProtocol%2FPortableContact.php;h=280dbe72c2a2afe151b5c5d47dd8e11a561fc182;hb=3a74f3364d28297ba957544893d9c721d683dba1;hp=1c44947f58052823a0a28598341f2a1fa76b977a;hpb=e06fc2aa6900d8cf5ae4e8d5cf52f9262bf7ada7;p=friendica.git diff --git a/src/Protocol/PortableContact.php b/src/Protocol/PortableContact.php index 1c44947f58..280dbe72c2 100644 --- a/src/Protocol/PortableContact.php +++ b/src/Protocol/PortableContact.php @@ -333,7 +333,7 @@ class PortableContact $server_url = normalise_link(self::detectServer($profile)); } - if (!in_array($gcontacts[0]["network"], [Protocol::DFRN, Protocol::DIASPORA, Protocol::FEED, Protocol::OSTATUS, ""])) { + if (!in_array($gcontacts[0]["network"], [Protocol::ACTIVITYPUB, Protocol::DFRN, Protocol::DIASPORA, Protocol::FEED, Protocol::OSTATUS, ""])) { logger("Profile ".$profile.": Network type ".$gcontacts[0]["network"]." can't be checked", LOGGER_DEBUG); return false; } @@ -1157,9 +1157,9 @@ class PortableContact if (isset($data['version'])) { $platform = "Mastodon"; - $version = $data['version']; - $site_name = $data['title']; - $info = $data['description']; + $version = defaults($data, 'version', ''); + $site_name = defaults($data, 'title', ''); + $info = defaults($data, 'description', ''); $network = Protocol::OSTATUS; } @@ -1472,7 +1472,7 @@ class PortableContact $tags = []; foreach ($data['tags'] as $tag) { $tag = mb_strtolower($tag); - if (count($tag) < 100) { + if (strlen($tag) < 100) { $tags[$tag] = $tag; } }