Clean up a little code in the form builder.
This commit is contained in:
1 parent
1b09282378
commit
a782b81104
1 file changed
+2
-4
+2
-4
@@ -620,11 +620,9 @@ class FormBuilder {
|
|||||||
|
|
||||||
if ($this->missingOldAndModel($name)) return $checked;
|
if ($this->missingOldAndModel($name)) return $checked;
|
||||||
|
|
||||||
$valueAttribute = $this->getValueAttribute($name);
|
$posted = $this->getValueAttribute($name);
|
||||||
|
|
||||||
if (is_array($valueAttribute)) return in_array($value, $valueAttribute);
|
return is_array($posted) ? in_array($value, $posted) : (bool) $posted;
|
||||||
|
|
||||||
return (bool) $valueAttribute;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in new issue
Block a user