MINOR merged r70323 from trunk

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/branches/2.3@70663 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2009-01-23 01:52:11 +00:00 committed by Sam Minnee
parent 64956adc07
commit a48a119bcc

View File

@ -498,7 +498,7 @@ class LeftAndMain extends Controller {
$parentID = (int)$p->ParentID; $parentID = (int)$p->ParentID;
$id = $p->ID ? $p->ID : "new-$p->class-$p->ParentID"; $id = $p->ID ? $p->ID : "new-$p->class-$p->ParentID";
$treeTitle = Convert::raw2js($p->TreeTitle()); $treeTitle = Convert::raw2js($p->TreeTitle());
$hasChildren = is_numeric( $id ) && $p->AllChildren() ? ' unexpanded' : ''; $hasChildren = (is_numeric($id) && $p->AllChildren() && $p->AllChildren()->Count()) ? ' unexpanded' : '';
// Ensure there is definitly a node avaliable. if not, append to the home tree. // Ensure there is definitly a node avaliable. if not, append to the home tree.
$response = <<<JS $response = <<<JS