Code

Fixed multiple calls of config->search.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 24 Sep 2007 09:21:58 +0000 (09:21 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 24 Sep 2007 09:21:58 +0000 (09:21 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7385 594d385d-05f5-0310-b6e9-bd551577e9d8

include/class_plugin.inc
plugins/admin/systems/class_goService.inc

index b957567d12a77cab1a76cacc81634f114a3fc025..953f18ddaab3023caf0e722c82c3ce6e4a25aa6e 100644 (file)
@@ -598,10 +598,7 @@ class plugin
   function postmodify($add_attrs= array())
   {
     /* Find postcreate entries for this class */
-    $command= $this->config->search(get_class($this), "POSTMODIFY",array('menu'));
-    if ($command == "" && isset($this->config->data['TABS'])){
-      $command= $this->config->search(get_class($this), "POSTMODIFY",array('tabs'));
-    }
+    $command= $this->config->search(get_class($this), "POSTMODIFY",array('menu','tabs'));
 
     if ($command != ""){
 
@@ -633,11 +630,7 @@ class plugin
   function postremove($add_attrs= array())
   {
     /* Find postremove entries for this class */
-    $command= $this->config->search(get_class($this), "POSTREMOVE",array('menu'));
-    if ($command == "" && isset($this->config->data['TABS'])){
-      $command= $this->config->search(get_class($this), "POSTREMOVE",array('tabs'));
-    }
-
+    $command= $this->config->search(get_class($this), "POSTREMOVE",array('menu','tabs'));
     if ($command != ""){
 
       /* Additional attributes */
index afbbf3001b5106c016f97b56cc90c10d5f403540..edfd3d7d5be09a72320c841fa09f905965c67c4c 100644 (file)
@@ -178,11 +178,7 @@ class goService extends plugin{
   function action_hook($add_attrs= array())
   {
     /* Find postcreate entries for this class */
-    $command= $this->config->search(get_class($this), "ACTION_HOOK",array('menu'));
-    if ($command == "" && isset($this->config->data['TABS'])){
-      $command= $this->config->search(get_class($this), "ACTION_HOOK",array('tabs'));
-    }
-
+    $command= $this->config->search(get_class($this), "ACTION_HOOK",array('menu','tabs'));
     if ($command != ""){
 
       /* Walk through attribute list */