src/Util/Validator.php
public function errors(string $field = null)
    {
        if ($field !== null) {
            return $this->_errors[$field] ?? false;
        }

        return $this->_errors;
    }
public function errors(string $field = null)
    {
        if ($field !== null) {
            return $this->_errors[$field] ?? false;
        }

        return $this->_errors;
    }
public function errors ( string $ field = null ) { if ( $ field !== null ) { return $ this -> _errors [ $ field ] ?? false ; } return $ this -> _errors ; }
Get array of error messages

@param  null|string $field

@return array|bool
Get array of error messages