From 0b425dce6890f8d7da4702f5414f42ea3c528280 Mon Sep 17 00:00:00 2001 From: hickert Date: Thu, 7 Jan 2010 12:56:52 +0000 Subject: [PATCH] Do not display any license stuff until the gosaSupportDaemon is configured. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15107 594d385d-05f5-0310-b6e9-bd551577e9d8 --- .../opsi/admin/opsiLicenses/class_filterOpsiLicense.inc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gosa-plugins/opsi/admin/opsiLicenses/class_filterOpsiLicense.inc b/gosa-plugins/opsi/admin/opsiLicenses/class_filterOpsiLicense.inc index e2998f61a..10d0e1958 100644 --- a/gosa-plugins/opsi/admin/opsiLicenses/class_filterOpsiLicense.inc +++ b/gosa-plugins/opsi/admin/opsiLicenses/class_filterOpsiLicense.inc @@ -4,6 +4,9 @@ class filterOpsiLicense { static function query($base, $scope, $filter, $attributes, $category, $objectStorage= "") { + + if(!class_available('opsi')) return(array()); + $config= session::global_get('config'); $ldap= $config->get_ldap_link(TRUE); $flag= ($scope == "sub")?GL_SUBSEARCH:0; @@ -25,6 +28,9 @@ class filterOpsiLicense { { $config= session::global_get('config'); $si = new opsiLicenceHandler($config); + + if(!$si->enabled()) return(array()); + $res = $si->listPools(); $result = array(); if($si->is_error() || !is_array($res)){ -- 2.30.2