src/Helper/ValidationHelper.php
protected function addError($attribute, $message)
    {
        if (!isset($this->errors[$attribute])) {
            $this->errors[$attribute] = array();
        }
        $this->errors[$attribute][] = $message;
    }
protected function addError($attribute, $message)
    {
        if (!isset($this->errors[$attribute])) {
            $this->errors[$attribute] = array();
        }
        $this->errors[$attribute][] = $message;
    }
protected function addError ( $ attribute , $ message ) { if ( ! isset ( $ this -> errors [ $ attribute ] ) ) { $ this -> errors [ $ attribute ] = array ( ) ; } $ this -> errors [ $ attribute ] [ ] = $ message ; }
Adds a new validation error message for the attribute.

@param string $attribute the attribute name.
@param string $message the error message.
Adds a new validation error message for the attribute .