diff options
author | Nicolas Grekas <nicolas.grekas@gmail.com> | 2015-06-19 14:55:04 +0200 |
---|---|---|
committer | Nicolas Grekas <nicolas.grekas@gmail.com> | 2015-07-16 11:00:04 +0200 |
commit | 472d48f6e32168bb7309a4869e469eb305d95f14 (patch) | |
tree | 21317d12e130ced3f7fcd9b8a26e3f6c423aa903 /apps/user_ldap/lib/access.php | |
parent | 5c2646a4bfe235487ba4177bd5733a278ab2101e (diff) | |
download | nextcloud-server-472d48f6e32168bb7309a4869e469eb305d95f14.tar.gz nextcloud-server-472d48f6e32168bb7309a4869e469eb305d95f14.zip |
Do not use OC*::mb_*_replace(), they are useless
Diffstat (limited to 'apps/user_ldap/lib/access.php')
-rw-r--r-- | apps/user_ldap/lib/access.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/apps/user_ldap/lib/access.php b/apps/user_ldap/lib/access.php index f38d11d4be3..c7747abee51 100644 --- a/apps/user_ldap/lib/access.php +++ b/apps/user_ldap/lib/access.php @@ -605,8 +605,7 @@ class Access extends LDAPUtility implements user\IUserTools { */ public function fetchUsersByLoginName($loginName, $attributes = array('dn')) { $loginName = $this->escapeFilterPart($loginName); - $filter = \OCP\Util::mb_str_replace( - '%uid', $loginName, $this->connection->ldapLoginFilter, 'UTF-8'); + $filter = str_replace('%uid', $loginName, $this->connection->ldapLoginFilter); $users = $this->fetchListOfUsers($filter, $attributes); return $users; } @@ -985,7 +984,7 @@ class Access extends LDAPUtility implements user\IUserTools { $name = iconv('UTF-8', 'ASCII//TRANSLIT', $name); // Replacements - $name = \OCP\Util::mb_str_replace(' ', '_', $name, 'UTF-8'); + $name = str_replace(' ', '_', $name); // Every remaining disallowed characters will be removed $name = preg_replace('/[^a-zA-Z0-9_.@-]/u', '', $name); |