Code

Updated groupware tabs
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 9 Sep 2010 07:01:45 +0000 (07:01 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Thu, 9 Sep 2010 07:01:45 +0000 (07:01 +0000)
-Fixes errors while removing ogroups with no members that still have some member related attributes set.

git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@19573 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/plugins/admin/ogroups/tabs_ogroups.inc

index 740eb25c0b3a537a21383f2a61d1db71034211ac..a1c51dae4b1c8958ccc1118f67c68ca9e661af0e 100644 (file)
@@ -365,11 +365,8 @@ class ogrouptabs extends tabs
             $this->dn= 'cn='.$baseobject->cn.','.get_ou("group", "ogroupRDN").$baseobject->base;
         }
 
-        /* Only delete attributes if there are members left */
-        if (count($this->by_object['ogroup']->memberList) != 0) {
-            foreach(array_keys($this->to_remove) as $object) {
-                $this->to_remove[$object]->remove_from_parent();
-            }
+        foreach(array_keys($this->to_remove) as $object) {
+            $this->to_remove[$object]->remove_from_parent();
         }
         tabs::save();
     }