mirror of
https://github.com/yiisoft/yii2.git
synced 2026-03-03 05:54:32 +01:00
Fixes #1870: Validation errors weren't properly translated when using clientside validation
This commit is contained in:
@@ -80,8 +80,8 @@ class RegularExpressionValidator extends Validator
|
||||
$options = [
|
||||
'pattern' => new JsExpression($pattern),
|
||||
'not' => $this->not,
|
||||
'message' => strtr($this->message, [
|
||||
'{attribute}' => $object->getAttributeLabel($attribute),
|
||||
'message' => Yii::t('yii', $this->message, [
|
||||
'attribute' => $object->getAttributeLabel($attribute),
|
||||
]),
|
||||
];
|
||||
if ($this->skipOnEmpty) {
|
||||
|
||||
Reference in New Issue
Block a user