diff options
author | Arthur Schiwon <blizzz@owncloud.com> | 2013-01-08 19:00:49 +0100 |
---|---|---|
committer | Arthur Schiwon <blizzz@owncloud.com> | 2013-01-08 19:00:49 +0100 |
commit | 19fa78d1ee7a41f2051be310b4579c4e36f3e546 (patch) | |
tree | c2440c0ba9f756f5f9870a8d92c698a36257c8ad /apps/user_ldap/lib | |
parent | ec1caa7d35aa12a35526a336c9b0a1464ed18cb3 (diff) | |
download | nextcloud-server-19fa78d1ee7a41f2051be310b4579c4e36f3e546.tar.gz nextcloud-server-19fa78d1ee7a41f2051be310b4579c4e36f3e546.zip |
Code style
Diffstat (limited to 'apps/user_ldap/lib')
-rw-r--r-- | apps/user_ldap/lib/access.php | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index fec08b72a37..89b652ad4b5 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -221,7 +221,9 @@ abstract class Access { * returns the internal ownCloud name for the given LDAP DN of the group, false on DN outside of search DN or failure */ public function dn2groupname($dn, $ldapname = null) { - //To avoid bypassing the base DN settings under certain circumstances with the group support, check whether the provided DN matches one of the given Bases + //To avoid bypassing the base DN settings under certain circumstances + //with the group support, check whether the provided DN matches one of + //the given Bases if(!$this->isDNPartOfBase($dn, $this->connection->ldapBaseGroups)) { return false; } @@ -238,7 +240,9 @@ abstract class Access { * returns the internal ownCloud name for the given LDAP DN of the user, false on DN outside of search DN or failure */ public function dn2username($dn, $ldapname = null) { - //To avoid bypassing the base DN settings under certain circumstances with the group support, check whether the provided DN matches one of the given Bases + //To avoid bypassing the base DN settings under certain circumstances + //with the group support, check whether the provided DN matches one of + //the given Bases if(!$this->isDNPartOfBase($dn, $this->connection->ldapBaseUsers)) { return false; } @@ -826,12 +830,12 @@ abstract class Access { $bases = $this->sanitizeDN($bases); foreach($bases as $base) { $belongsToBase = true; - if(mb_strripos($dn, $base, 0, 'UTF-8') !== (mb_strlen($dn, 'UTF-8')-mb_strlen($base))) { + if(mb_strripos($dn, $base, 0, 'UTF-8') !== (mb_strlen($dn, 'UTF-8')-mb_strlen($base))) { $belongsToBase = false; - } - if($belongsToBase) { + } + if($belongsToBase) { break; - } + } } return $belongsToBase; } |