From d6bec26155fc5f74a0154dadc662ebdb6c161ca7 Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 11 Mar 2008 10:05:40 +0000 Subject: [PATCH] Updated check. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9661 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../systems/admin/systems/class_servGeneric.inc | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/gosa-plugins/systems/admin/systems/class_servGeneric.inc b/gosa-plugins/systems/admin/systems/class_servGeneric.inc index 9b2e16c0f..5bf6e46ec 100644 --- a/gosa-plugins/systems/admin/systems/class_servGeneric.inc +++ b/gosa-plugins/systems/admin/systems/class_servGeneric.inc @@ -79,13 +79,15 @@ class servgeneric extends plugin $this->netConfigDNS->set_acl_base($this->base); /* Check if this host is currently in installation process*/ - $o = new gosaSupportDaemon(); - $e_types = DaemonEvent::get_event_types(USER_EVENT | SYSTEM_EVENT | HIDDEN_EVENT); - $evts = $o->get_entries_by_mac(array($this->netConfigDNS->macAddress)); - foreach($evts as $evt){ - if(isset($e_types['QUEUED'][$evt['HEADERTAG']]) && $evt['STATUS'] == "processing" && - $e_types['QUEUED'][$evt['HEADERTAG']] == "DaemonEvent_reinstall"){ - $this->currently_installing =TRUE; + if(class_available("gosaSupportDaemon") && class_available("DaemonEvent")){ + $o = new gosaSupportDaemon(); + $e_types = DaemonEvent::get_event_types(USER_EVENT | SYSTEM_EVENT | HIDDEN_EVENT); + $evts = $o->get_entries_by_mac(array($this->netConfigDNS->macAddress)); + foreach($evts as $evt){ + if(isset($e_types['QUEUED'][$evt['HEADERTAG']]) && $evt['STATUS'] == "processing" && + $e_types['QUEUED'][$evt['HEADERTAG']] == "DaemonEvent_reinstall"){ + $this->currently_installing =TRUE; + } } } -- 2.30.2