mlanthaler: Bugfix: Fixed E_NOTICE error due to uninitialized variable

(merged from branches/gsoc)


git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/cms/trunk@41960 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
Ingo Schommer 2007-09-15 21:54:24 +00:00
parent dcc83f8ff3
commit abca2d257a

View File

@ -407,6 +407,7 @@ JS;
$descendantIDs = $record->getDescendantIDList('SiteTree');
// then delete them from the live site too
$descendantsRemoved = 0;
foreach( $descendantIDs as $descID )
if( $descendant = DataObject::get_by_id('SiteTree', $descID) ) {
$descendant->delete();