renamed $object to $model

This commit is contained in:
Qiang Xue
2014-10-31 14:56:59 -04:00
parent a0bd20334f
commit d13d274d05
18 changed files with 100 additions and 100 deletions

View File

@ -62,7 +62,7 @@ class RegularExpressionValidator extends Validator
/**
* @inheritdoc
*/
public function clientValidateAttribute($object, $attribute, $view)
public function clientValidateAttribute($model, $attribute, $view)
{
$pattern = $this->pattern;
$pattern = preg_replace('/\\\\x\{?([0-9a-fA-F]+)\}?/', '\u$1', $pattern);
@ -82,7 +82,7 @@ class RegularExpressionValidator extends Validator
'pattern' => new JsExpression($pattern),
'not' => $this->not,
'message' => Yii::$app->getI18n()->format($this->message, [
'attribute' => $object->getAttributeLabel($attribute),
'attribute' => $model->getAttributeLabel($attribute),
], Yii::$app->language),
];
if ($this->skipOnEmpty) {