From 3dcbd0ae3007fcf71967a06437ef7150bedf9711 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sat, 28 Oct 2006 09:32:04 +0000 Subject: [PATCH] fixed adi's patch to allow again searching in other fields then the one used in account-filter (by default uid) --- phpgwapi/inc/class.accounts_ldap.inc.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/phpgwapi/inc/class.accounts_ldap.inc.php b/phpgwapi/inc/class.accounts_ldap.inc.php index 9158afd527..2d35ac5894 100644 --- a/phpgwapi/inc/class.accounts_ldap.inc.php +++ b/phpgwapi/inc/class.accounts_ldap.inc.php @@ -659,10 +659,9 @@ class accounts_backend $filter .= '(|(uid='.implode(')(uid=',$members).'))'; } - // add account_filter to filter (and make $query a wildcard if empty) + // add account_filter to filter (user has to be '*', as we otherwise only search uid's) $filter .= $this->account_filter; - if (empty($query)) $query = '*'; - $filter = str_replace(array('%user','%domain'),array($query,$GLOBALS['egw_info']['user']['domain']),$filter); + $filter = str_replace(array('%user','%domain'),array('*',$GLOBALS['egw_info']['user']['domain']),$filter); $filter .= ')'; $sri = ldap_search($this->ds, $this->user_context, $filter,array('uid','uidNumber','givenname','sn','mail','shadowExpire'));