mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 00:24:40 +00:00
MVC / BaseField - two regressions in fc8890851a
o GetInternalIsVirtual --> getInternalIsVirtual o spurious getInternalIsVirtual() in setNodes() on null object for https://github.com/opnsense/core/issues/5874
This commit is contained in:
parent
fd529812e4
commit
9cc07ed4ac
@ -498,7 +498,7 @@ abstract class BaseField
|
||||
$parentNode = $this->getParentNode();
|
||||
if (count($parts) == 2) {
|
||||
$tagName = $parts[0];
|
||||
if (isset($parentNode->$tagName) && !$parentNode->$tagName->GetInternalIsVirtual()) {
|
||||
if (isset($parentNode->$tagName) && !$parentNode->$tagName->getInternalIsVirtual()) {
|
||||
$ref_constraint = $parentNode->$tagName->getConstraintByName($parts[1]);
|
||||
if ($ref_constraint != null) {
|
||||
$result[] = $ref_constraint;
|
||||
@ -629,7 +629,7 @@ abstract class BaseField
|
||||
// add new items to array type objects
|
||||
if ($this->isArrayType()) {
|
||||
foreach ($data as $dataKey => $dataValue) {
|
||||
if (!isset($this->$dataKey) && !$this->$dataKey->GetInternalIsVirtual()) {
|
||||
if (!isset($this->$dataKey)) {
|
||||
$node = $this->add();
|
||||
$node->setNodes($dataValue);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user