RouteDispatcher: Fixed string conversion

This commit is contained in:
Igor Scheller 2023-04-01 17:02:39 +02:00
parent c85eb2f3d2
commit ca6e0813ba
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ class RouteDispatcher implements MiddlewareInterface
*/ */
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
{ {
$path = (new Uri($request->getUri()))->getPath(); $path = (new Uri((string) $request->getUri()))->getPath();
if ($request instanceof Request) { if ($request instanceof Request) {
$path = $request->getPathInfo(); $path = $request->getPathInfo();
} }