public static function run(array $stack, ServerRequestInterface $request = null): ResponseInterface
    {
        if ($request === null) {
            $request = Factory::createServerRequest('GET', '/');
        }

        return (new static($stack))->dispatch($request);
    }
public static function run(array $stack, ServerRequestInterface $request = null): ResponseInterface
    {
        if ($request === null) {
            $request = Factory::createServerRequest('GET', '/');
        }

        return (new static($stack))->dispatch($request);
    }
public static function run ( array $ stack , ServerRequestInterface $ request = null ) : ResponseInterface { if ( $ request === null ) { $ request = Factory :: createServerRequest ( 'GET' , '/' ) ; } return ( new static ( $ stack ) ) -> dispatch ( $ request ) ; }
Static helper to create and dispatch a request.
Static helper to create and dispatch a request .