src/bitExpert/Pathfinder/Middleware/BasicRoutingMiddleware.php
protected function applyRoutingResult(
        ServerRequestInterface $request,
        RoutingResult $routingResult
    ) : ServerRequestInterface {
        $routingParams = $routingResult->getParams();
        $params = array_merge($request->getQueryParams(), $routingParams);
        return $request->withQueryParams($params);
    }
protected function applyRoutingResult(
        ServerRequestInterface $request,
        RoutingResult $routingResult
    ) : ServerRequestInterface {
        $routingParams = $routingResult->getParams();
        $params = array_merge($request->getQueryParams(), $routingParams);
        return $request->withQueryParams($params);
    }
Offers possibility to manipulate the request according to routing result.
Returns a new {@link \Psr\Http\Message\ServerRequestInterface}.

@param ServerRequestInterface $request
@param RoutingResult $routingResult
@return ServerRequestInterface