summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2013-07-04 20:01:21 +0200
committerThomas Bruederli <bruederli@kolabsys.com>2013-07-04 20:01:21 +0200
commite6a7be8b1f9531e35ecf3ed79553072bb2585418 (patch)
tree080f92810787b9010e3e19f52055b166e2adfa33 /program
parentc3fe8a0b7a04bb0b27d69f60bb893264f77b30e0 (diff)
Don't add filters for required fields which are already in search filter
Diffstat (limited to 'program')
-rw-r--r--program/lib/Roundcube/rcube_ldap.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/program/lib/Roundcube/rcube_ldap.php b/program/lib/Roundcube/rcube_ldap.php
index 922c73568..7c4002337 100644
--- a/program/lib/Roundcube/rcube_ldap.php
+++ b/program/lib/Roundcube/rcube_ldap.php
@@ -871,6 +871,8 @@ class rcube_ldap extends rcube_addressbook
// add required (non empty) fields filter
$req_filter = '';
foreach ((array)$required as $field) {
+ if (in_array($field, (array)$fields)) // required field is already in search filter
+ continue;
if ($attrs = $this->_map_field($field)) {
if (count($attrs) > 1)
$req_filter .= '(|';