From 020ba7a4eddb94250c530da5e3cd85ffee8101bd Mon Sep 17 00:00:00 2001 From: Michael Date: Wed, 11 May 2022 06:58:26 +0000 Subject: [PATCH] The function is now usable for all formats --- src/Util/Network.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Util/Network.php b/src/Util/Network.php index cdcb39a496..7d935d55f0 100644 --- a/src/Util/Network.php +++ b/src/Util/Network.php @@ -474,10 +474,12 @@ class Network if (!empty($parts['scheme']) && !empty($parts['host'])) { $parts['host'] = idn_to_ascii($parts['host']); $uri = self::unparseURL($parts); - } elseif (strstr($uri, '@')) { + } else { $parts = explode('@', $uri); if (count($parts) == 2) { $uri = $parts[0] . '@' . idn_to_ascii($parts[1]); + } else { + $uri = idn_to_ascii($uri); } }