From f6835667f7f739a42111769fbaf3850d05faaf42 Mon Sep 17 00:00:00 2001 From: Ronan Giron Date: Mon, 24 Apr 2023 16:21:09 +0200 Subject: [PATCH] Uri's creation with string port instead of integer --- CHANGELOG.md | 6 ++++++ src/Router.php | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f29c73..5276b3a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. This projec to [Semantic Versioning] (http://semver.org/). For change log format, use [Keep a Changelog] (http://keepachangelog.com/). +## [1.3.1] - 2023-04-24 + +### Fixed + +- Uri's creation with string port instead of integer + ## [1.3.0] - 2023-04-14 ### Added diff --git a/src/Router.php b/src/Router.php index 29418a1..975f6b5 100644 --- a/src/Router.php +++ b/src/Router.php @@ -168,7 +168,7 @@ public static function makeServerRequest(): ServerRequestInterface $requestUri = new Uri( $_SERVER['REQUEST_SCHEME'] ?? '', $_SERVER['HTTP_HOST'] ?? '', - $_SERVER['SERVER_PORT'] ?? 80, + (int)($_SERVER['SERVER_PORT'] ?? 80), $path ?? '', $queryString, '',