Commit 6c2cf9a2 by Qiang Xue

Removed redundant code.

parent 7a587f62
...@@ -160,12 +160,10 @@ class Model extends Component implements \IteratorAggregate, \ArrayAccess ...@@ -160,12 +160,10 @@ class Model extends Component implements \IteratorAggregate, \ArrayAccess
{ {
$attributes = array(); $attributes = array();
foreach ($this->getActiveValidators() as $validator) { foreach ($this->getActiveValidators() as $validator) {
if ($validator->isActive('default')) {
foreach ($validator->attributes as $name) { foreach ($validator->attributes as $name) {
$attributes[$name] = true; $attributes[$name] = true;
} }
} }
}
return array( return array(
'default' => array_keys($attributes), 'default' => array_keys($attributes),
); );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment