getMessage(), 2); return $errorType; } /** * Converts the exception to an instance of Predis\Response\Error. * * @return Error */ public function toErrorResponse() { return new Error($this->getMessage()); } }