From 5e145cc0d88907a33058ad6b3fc31dfc6d34927d Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 24 Apr 2007 09:07:34 +0000 Subject: [PATCH] Fixed acl handling for group membership in posix dialog git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6185 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/personal/posix/class_posixAccount.inc | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/plugins/personal/posix/class_posixAccount.inc b/plugins/personal/posix/class_posixAccount.inc index 340e6f301..6668f1cbb 100644 --- a/plugins/personal/posix/class_posixAccount.inc +++ b/plugins/personal/posix/class_posixAccount.inc @@ -1020,15 +1020,14 @@ class posixAccount extends plugin function delGroup ($groups) { $dest= array(); - - foreach ($this->groupMembership as $key => $value){ - if ((!in_array($key, $groups)) || (obj_is_writable($attrs['dn'],"groups/group","memberUid"))){ - $dest[$key]= $value; + foreach($groups as $dn_to_del){ + if(isset($this->groupMembership[$dn_to_del]) && obj_is_writable($dn_to_del,"groups/group","memberUid")){ + unset($this->groupMembership[$dn_to_del]); } } - $this->groupMembership= $dest; } + /* Adapt from template, using 'dn' */ function adapt_from_template($dn) { -- 2.30.2