lib/Elastica/Exception/ElasticsearchException.php
protected function _parseError(string $error)
    {
        $errors = \explode(']; nested: ', $error);

        if (1 === \count($errors)) {
            $this->_exception = $this->_extractException($errors[0]);
        } else {
            if (self::REMOTE_TRANSPORT_EXCEPTION === $this->_extractException($errors[0])) {
                $this->_isRemote = true;
                $this->_exception = $this->_extractException($errors[1]);
            } else {
                $this->_exception = $this->_extractException($errors[0]);
            }
        }
    }
protected function _parseError(string $error)
    {
        $errors = \explode(']; nested: ', $error);

        if (1 === \count($errors)) {
            $this->_exception = $this->_extractException($errors[0]);
        } else {
            if (self::REMOTE_TRANSPORT_EXCEPTION === $this->_extractException($errors[0])) {
                $this->_isRemote = true;
                $this->_exception = $this->_extractException($errors[1]);
            } else {
                $this->_exception = $this->_extractException($errors[0]);
            }
        }
    }
protected function _parseError ( string $ error ) { $ errors = \ explode ( ']; nested: ' , $ error ) ; if ( 1 === \ count ( $ errors ) ) { $ this -> _exception = $ this -> _extractException ( $ errors [ 0 ] ) ; } else { if ( self :: REMOTE_TRANSPORT_EXCEPTION === $ this -> _extractException ( $ errors [ 0 ] ) ) { $ this -> _isRemote = true ; $ this -> _exception = $ this -> _extractException ( $ errors [ 1 ] ) ; } else { $ this -> _exception = $ this -> _extractException ( $ errors [ 0 ] ) ; } } }
Parse error message from elasticsearch.

@param string $error Error message
Parse error message from elasticsearch .