From: hickert Date: Wed, 17 Dec 2008 10:10:01 +0000 (+0000) Subject: Updated group mail and kolab 22 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=adc099ffac688e47a222b7edb2aa3b0c6565eec8;p=gosa.git Updated group mail and kolab 22 git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@13301 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/kolab/personal/mail/kolab/class_mail-methods-kolab22.inc b/gosa-plugins/kolab/personal/mail/kolab/class_mail-methods-kolab22.inc index 3a1de4250..3742b7adb 100644 --- a/gosa-plugins/kolab/personal/mail/kolab/class_mail-methods-kolab22.inc +++ b/gosa-plugins/kolab/personal/mail/kolab/class_mail-methods-kolab22.inc @@ -58,6 +58,15 @@ class mailMethodKolab22 extends mailMethodKolab } } + /* Merge given ACL with acl mapping + This ensures that no ACL will accidentally overwritten by gosa. + */ + foreach($ldap_acls as $user => $acl){ + if(!isset($this->acl_mapping[$acl])){ + $this->acl_mapping[$acl] = $acl; + } + } + return($ldap_acls); } diff --git a/gosa-plugins/mail/admin/groups/mail/class_groupMail.inc b/gosa-plugins/mail/admin/groups/mail/class_groupMail.inc index 78cf45519..735c3de1a 100644 --- a/gosa-plugins/mail/admin/groups/mail/class_groupMail.inc +++ b/gosa-plugins/mail/admin/groups/mail/class_groupMail.inc @@ -172,10 +172,12 @@ class mailgroup extends plugin */ if(count($this->folder_acls) > 2){ $acl_usage = array(); - $most_acl = ""; + $most_acl = $this->folder_acls['__member__']; $most_cnt = 0; $member = $this->get_member(); foreach($this->folder_acls as $user => $acl){ + if(preg_match("/^__/",$user)) continue; + if(!in_array($user,$member['mail'])) continue; if(!isset($acl_usage[$acl])) $acl_usage[$acl]=0; $acl_usage[$acl] ++; if($acl_usage[$acl] > $most_cnt){