diff --git a/libraries/navigation/NavigationTree.class.php b/libraries/navigation/NavigationTree.class.php index 124abfb0e2..36a2899d67 100644 --- a/libraries/navigation/NavigationTree.class.php +++ b/libraries/navigation/NavigationTree.class.php @@ -186,7 +186,9 @@ class PMA_NavigationTree { $retval = $table; $containers = $this->addTableContainers($table); array_shift($path); // remove table - foreach ($containers as $container) { + if (count($path) > 0 && array_key_exists($path[0], $containers)) { + $container = $table->getChild($path[0], true); + $retval = $container; foreach ($table->getData($container->real_name) as $item) { switch ($container->real_name) { case 'indexes': @@ -239,11 +241,10 @@ class PMA_NavigationTree { } // Add all new Nodes to the tree foreach ($retval as $node) { - $node->loaded = true; $table->addChild($node); } } else { - foreach ($db->children as $node) { + foreach ($table->children as $node) { $retval[$node->real_name] = $node; } } @@ -492,7 +493,7 @@ class PMA_NavigationTree { $v_path = implode('.', array_reverse($v_path)); $loaded = ''; - if ($node->loaded || $node->is_group || $GLOBALS['cfg']['LeftFrameLight'] != true) { + if ($node->is_group || $GLOBALS['cfg']['LeftFrameLight'] != true) { $loaded = ' loaded'; } $container = ''; diff --git a/libraries/navigation/Nodes/Node.class.php b/libraries/navigation/Nodes/Node.class.php index 930565b92c..a03d38aa05 100644 --- a/libraries/navigation/Nodes/Node.class.php +++ b/libraries/navigation/Nodes/Node.class.php @@ -83,12 +83,6 @@ class Node { */ protected $links; - /** - * @var string If the node is a container, this indicates if - * its children are already loaded - */ - private $loaded = false; - /** * @var string classes */ @@ -158,7 +152,6 @@ class Node { case 'separator': case 'separator_depth': case 'visible': - case 'loaded': $this->$a = $b; return true; default: