protected function setErrors($response)
    {
        libxml_use_internal_errors(true);

        $doc = new \DOMDocument('1.0', 'utf-8');
        $doc->loadXML($response);

        $errors = libxml_get_errors();
        if (!empty($errors)) {
            $this->errors[] = 'Xml response is invalid';
        }

        return $this;
    }
protected function setErrors($response)
    {
        libxml_use_internal_errors(true);

        $doc = new \DOMDocument('1.0', 'utf-8');
        $doc->loadXML($response);

        $errors = libxml_get_errors();
        if (!empty($errors)) {
            $this->errors[] = 'Xml response is invalid';
        }

        return $this;
    }
protected function setErrors ( $ response ) { libxml_use_internal_errors ( true ) ; $ doc = new \ DOMDocument ( '1.0' , 'utf-8' ) ; $ doc -> loadXML ( $ response ) ; $ errors = libxml_get_errors ( ) ; if ( ! empty ( $ errors ) ) { $ this -> errors [ ] = 'Xml response is invalid' ; } return $ this ; }
Set the xml errors

@param string $response
@return \Octopush\Client
Set the xml errors