From: hickert Date: Tue, 2 May 2006 09:01:19 +0000 (+0000) Subject: there must be at least one server with objectClass=goMailServer else the mail queue... X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=9cd10e2d1e2d825a1199a46fb7927411f2014517;p=gosa.git there must be at least one server with objectClass=goMailServer else the mail queue wont mwork git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3184 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/plugins/addons/mailqueue/class_mailqueue.inc b/plugins/addons/mailqueue/class_mailqueue.inc index c6e9e322d..eef36caed 100644 --- a/plugins/addons/mailqueue/class_mailqueue.inc +++ b/plugins/addons/mailqueue/class_mailqueue.inc @@ -64,6 +64,7 @@ class mailqueue extends plugin */ if($this->Server=="all"){ $se = $this->getServer(); + unset($se['all']); $se_str = ""; foreach($se as $server) { @@ -207,6 +208,15 @@ class mailqueue extends plugin } + /* Check for existing servers + objectClass=goMailServer is required at least for one server. + Else display error */ + $server = $this->getServer(); + if((count($server) == 1 ) && (isset($server['all']))){ + print_red(_("There are no mail server specified.")); + $error = true; + } + if(!$error){ /* Filter data with the given */