protected function reviveRequest(ServerRequestInterface $request)
    {
        $isStale = interface_exists('Jasny\HttpMessage\GlobalEnvironmentInterface') &&
            $request instanceof GlobalEnvironmentInterface &&
            $request->isStale();
        
        return $isStale ? $request->revive() : $request;
    }