From 19ebdcfb377e76147f406272d51c64ede643abe9 Mon Sep 17 00:00:00 2001 From: Johannes Meyer Date: Fri, 18 Sep 2015 12:20:44 +0200 Subject: [PATCH] NavigationConfigForm: Fix method getFlattenedChildren() refs #5600 --- application/forms/Navigation/NavigationConfigForm.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/application/forms/Navigation/NavigationConfigForm.php b/application/forms/Navigation/NavigationConfigForm.php index 838beb68a..3f0269fbe 100644 --- a/application/forms/Navigation/NavigationConfigForm.php +++ b/application/forms/Navigation/NavigationConfigForm.php @@ -227,8 +227,8 @@ class NavigationConfigForm extends ConfigForm } $children = array(); - foreach ($config as $sectionName => $sectionConfig) { - if ($sectionConfig->parent === $name) { + foreach ($config->toArray() as $sectionName => $sectionConfig) { + if (isset($sectionConfig['parent']) && $sectionConfig['parent'] === $name) { $children[] = $sectionName; $children = array_merge($children, $this->getFlattenedChildren($sectionName)); }