private static function getAuthority(array $parsed) { $userInfo = self::getUserInfo($parsed); $host = self::getHost($parsed); if (strlen($userInfo)) { return $userInfo . '@' . $host; } return $host; }