protected function createException(GuzzleRequestException $exception): RequestException
    {
        if ($exception instanceof GuzzleResponseException) {
            return new ResponseException(
                $exception->getRequest(),
                $exception->getResponse(),
                $exception
            );
        }

        throw new RequestException(
            $exception->getRequest(),
            $exception
        );
    }