library/Benri/Controller/Action/Abstract.php
protected function _pushError($resource, $code, $title, $message = '')
    {
        $this->_errors[] = [
            'code'      => $code,
            'message'   => $message,
            'resource'  => $resource,
            'title'     => $title,
        ];

        return $this;
    }
protected function _pushError($resource, $code, $title, $message = '')
    {
        $this->_errors[] = [
            'code'      => $code,
            'message'   => $message,
            'resource'  => $resource,
            'title'     => $title,
        ];

        return $this;
    }
protected function _pushError ( $ resource , $ code , $ title , $ message = '' ) { $ this -> _errors [ ] = [ 'code' => $ code , 'message' => $ message , 'resource' => $ resource , 'title' => $ title , ] ; return $ this ; }
All error objects have field and code properties so that your client
can tell what the problem is.

If resources have custom validation errors, they should be documented
with the resource.

@param string $resource The erroneous resource
@param string $code
@param string $title A title for the error
@param string $message A friendly message
@return self
All error objects have field and code properties so that your client can tell what the problem is .