NavigationConfigForm: Fix method getFlattenedChildren()

refs #5600
This commit is contained in:
Johannes Meyer 2015-09-18 12:20:44 +02:00
parent 37c7952ec7
commit 19ebdcfb37

View File

@ -227,8 +227,8 @@ class NavigationConfigForm extends ConfigForm
} }
$children = array(); $children = array();
foreach ($config as $sectionName => $sectionConfig) { foreach ($config->toArray() as $sectionName => $sectionConfig) {
if ($sectionConfig->parent === $name) { if (isset($sectionConfig['parent']) && $sectionConfig['parent'] === $name) {
$children[] = $sectionName; $children[] = $sectionName;
$children = array_merge($children, $this->getFlattenedChildren($sectionName)); $children = array_merge($children, $this->getFlattenedChildren($sectionName));
} }