From 0971bcf165dae452901f5cec210b7f39342eee88 Mon Sep 17 00:00:00 2001 From: Michael Date: Fri, 29 Jul 2022 16:05:04 +0000 Subject: [PATCH] Make the tests happy --- src/Model/APContact.php | 4 ++-- src/Model/Item.php | 2 +- src/Protocol/DFRN.php | 2 +- src/Protocol/Diaspora.php | 2 +- src/Util/Network.php | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Model/APContact.php b/src/Model/APContact.php index bb6f12e10..38ec423e8 100644 --- a/src/Model/APContact.php +++ b/src/Model/APContact.php @@ -383,11 +383,11 @@ class APContact if (strlen($apcontact['photo']) > 255) { $parts = parse_url($apcontact['photo']); unset($parts['fragment']); - $apcontact['photo'] = Uri::fromParts($parts); + $apcontact['photo'] = (string)Uri::fromParts($parts); if (strlen($apcontact['photo']) > 255) { unset($parts['query']); - $apcontact['photo'] = Uri::fromParts($parts); + $apcontact['photo'] = (string)Uri::fromParts($parts); } if (strlen($apcontact['photo']) > 255) { diff --git a/src/Model/Item.php b/src/Model/Item.php index e0ca50717..73a6e65c5 100644 --- a/src/Model/Item.php +++ b/src/Model/Item.php @@ -2948,7 +2948,7 @@ class Item if (!empty($urlparts)) { unset($urlparts['query']); unset($urlparts['fragment']); - $url = Uri::fromParts($urlparts); + $url = (string)Uri::fromParts($urlparts); } else { return false; } diff --git a/src/Protocol/DFRN.php b/src/Protocol/DFRN.php index 7593711e5..89ffca153 100644 --- a/src/Protocol/DFRN.php +++ b/src/Protocol/DFRN.php @@ -998,7 +998,7 @@ class DFRN $path_parts = explode('/', $parts['path']); array_pop($path_parts); $parts['path'] = implode('/', $path_parts); - $contact['batch'] = Uri::fromParts($parts); + $contact['batch'] = (string)Uri::fromParts($parts); } $dest_url = ($public_batch ? $contact['batch'] : $contact['notify']); diff --git a/src/Protocol/Diaspora.php b/src/Protocol/Diaspora.php index cc0293669..c5ad51215 100644 --- a/src/Protocol/Diaspora.php +++ b/src/Protocol/Diaspora.php @@ -1419,7 +1419,7 @@ class Diaspora $parts = parse_url($person['url']); unset($parts['path']); - $host_url = Uri::fromParts($parts); + $host_url = (string)Uri::fromParts($parts); return $host_url . '/objects/' . $guid; } diff --git a/src/Util/Network.php b/src/Util/Network.php index 23def7e57..63cc67f4c 100644 --- a/src/Util/Network.php +++ b/src/Util/Network.php @@ -497,7 +497,7 @@ class Network $parts = parse_url($uri); if (!empty($parts['scheme']) && !empty($parts['host'])) { $parts['host'] = idn_to_ascii($parts['host']); - $uri = Uri::fromParts($parts); + $uri = (string)Uri::fromParts($parts); } else { $parts = explode('@', $uri); if (count($parts) == 2) {