public function normalizeError($error)
    {
        if ($error instanceof \Exception) {
            return new AdaptorException($error->getMessage(), $error->getCode(), $error);
        }

        return new AdaptorException(
            sprintf('An error accord: %s', print_r($error, true)),
            AdaptorException::UNKNOWN_ERROR
        );
    }