Code

Fixed service remove.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 4 Jun 2008 11:18:38 +0000 (11:18 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 4 Jun 2008 11:18:38 +0000 (11:18 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@11207 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-plugins/apache2/admin/systems/services/apache2/class_servApacheVhost.inc

index 51c7c4d1677d5a2b9ee7383477c32c8cc2b111f1..3c6b572b7c526ce71a006c384bf5e8e4ce7c08e9 100644 (file)
@@ -33,7 +33,7 @@ class servapache extends goService
   var $dialog           = NULL;
   var $orig_dn          = "";
 
-  var $APACHEinitially_was_account;
+  var $initially_was_account;
 
 
   function servapache ($config, $dn= NULL, $parent= NULL)
@@ -53,7 +53,7 @@ class servapache extends goService
     }else{
       $this->is_account = true;
     }
-    $this->APACHEinitially_was_account = $this->is_account;
+    $this->initially_was_account = $this->is_account;
 
     /* Set service name */
     $this->DisplayName = _("Apache service");
@@ -200,17 +200,10 @@ class servapache extends goService
    */
   function remove_from_parent()
   {
-    if($this->APACHEinitially_was_account){
-      $bool = true;
-      foreach($this->Vhosts as $key => $vhost){
-        $bool= $bool & $this->RemoveVhost($key);
-      }
-
-      if($bool){
-        $this->save();
-      }
-      return($bool);
+    foreach($this->Vhosts as $key => $vhost){
+      $this->RemoveVhost($key);
     }
+    $this->save();
   }