From: hickert Date: Fri, 21 Aug 2009 11:02:25 +0000 (+0000) Subject: Updated class acl again. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=0d227569a51c4cacf389dda8f98370642f86fc37;p=gosa.git Updated class acl again. -It seems that we can have objects without both cn and uid.... git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14104 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-core/include/class_acl.inc b/gosa-core/include/class_acl.inc index b2e3ca093..02d0a41a1 100644 --- a/gosa-core/include/class_acl.inc +++ b/gosa-core/include/class_acl.inc @@ -89,8 +89,12 @@ class acl extends plugin while ($attrs= $ldap->fetch()){ // Allow objects without cn to be listed without causing an error. - if(!isset($attrs['uid'][0])){ + if(!isset($attrs['cn'][0]) && isset($attrs['uid'][0])){ + $this->users['U:'.$attrs['dn']]= $attrs['uid'][0]; + }elseif(!isset($attrs['uid'][0]) && isset($attrs['cn'][0])){ $this->users['U:'.$attrs['dn']]= $attrs['cn'][0]; + }elseif(!isset($attrs['uid'][0]) && !isset($attrs['cn'][0])){ + $this->users['U:'.$attrs['dn']]= $attrs['dn']; }else{ $this->users['U:'.$attrs['dn']]= $attrs['cn'][0].' ['.$attrs['uid'][0].']'; }