From 817347ebbba6aee62913cff3001a257d363254c1 Mon Sep 17 00:00:00 2001 From: yggverse Date: Sun, 28 Apr 2024 02:55:14 +0300 Subject: [PATCH] build connection url to parse ipv6 #72811 --- src/nex.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/nex.php b/src/nex.php index c3f06e7..7fac10f 100644 --- a/src/nex.php +++ b/src/nex.php @@ -314,6 +314,12 @@ $server->start( // Dump request on enabled if (NEXT_DUMP) { + // Build connection URL #72811 + $url = sprintf( + 'nex://%s', + $connect + ); + printf( str_ireplace( [ @@ -327,8 +333,8 @@ $server->start( [ (string) date('c'), (string) (int) !empty($response), - (string) parse_url($connect, PHP_URL_HOST), - (string) parse_url($connect, PHP_URL_PORT), + (string) parse_url($url, PHP_URL_HOST), + (string) parse_url($url, PHP_URL_PORT), (string) str_replace('%', '%%', empty($request) ? '/' : $request), (string) str_replace('%', '%%', $realpath) ],