Browse Source

bug fix: autocomplete fails if contactlist_fields contains vcard fields

pull/9832/head
PhilW 4 months ago
parent
commit
53f50dc080
  1. 11
      program/lib/Roundcube/rcube_contacts.php

11
program/lib/Roundcube/rcube_contacts.php

@ -347,7 +347,16 @@ class rcube_contacts extends rcube_addressbook
foreach ($words as $word) {
$groups = [];
foreach ((array) $fields as $idx => $col) {
$groups[] = $this->fulltext_sql_where($word, $mode, $col);
// table column
if (in_array($col, $this->table_cols)) {
$groups[] = $this->fulltext_sql_where($word, $mode, $col);
}
// vCard field
else {
if (in_array($col, $this->fulltext_cols)) {
$groups[] = $this->fulltext_sql_where($word, $mode, 'words');
}
}
}
$where[] = '(' . implode(' OR ', $groups) . ')';
}

Loading…
Cancel
Save