diff --git a/security/Group.php b/security/Group.php index 98aa0e7a5..d8db38588 100644 --- a/security/Group.php +++ b/security/Group.php @@ -191,7 +191,7 @@ class Group extends DataObject { $children = $this->extInstance('Hierarchy')->AllChildrenIncludingDeleted(); $filteredChildren = new DataObjectSet(); - foreach($children as $child) { + if($children) foreach($children as $child) { if($child->canEdit()) $filteredChildren->push($child); }