protected function getErrorMessage($name, $params = [])
    {
        if ($this->simpleErrorMessage) {
            $name = 'message';
        }
        if (isset($this->$name)) {
            return [$this->$name, $params];
        }
        $this->$name = Yii::t('kdn/yii2/validators/domain', $this->getDefaultErrorMessages()[$name]);
        return [$this->$name, $params];
    }
protected function getErrorMessage($name, $params = [])
    {
        if ($this->simpleErrorMessage) {
            $name = 'message';
        }
        if (isset($this->$name)) {
            return [$this->$name, $params];
        }
        $this->$name = Yii::t('kdn/yii2/validators/domain', $this->getDefaultErrorMessages()[$name]);
        return [$this->$name, $params];
    }
protected function getErrorMessage ( $ name , $ params = [ ] ) { if ( $ this -> simpleErrorMessage ) { $ name = 'message' ; } if ( isset ( $ this -> $ name ) ) { return [ $ this -> $ name , $ params ] ; } $ this -> $ name = Yii :: t ( 'kdn/yii2/validators/domain' , $ this -> getDefaultErrorMessages ( ) [ $ name ] ) ; return [ $ this -> $ name , $ params ] ; }
Get error message by name.
@param string $name error message name
@param array $params parameters to be inserted into the error message
@return array error message.
Get error message by name .