From 4cd090aa243f2feca9c6ca620a2393c3ceed8d65 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Tue, 7 Feb 2017 09:56:34 +0100 Subject: [PATCH] Fix regression where groups with email address were resolved to its members' addresses --- CHANGELOG | 1 + program/steps/mail/autocomplete.inc | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/CHANGELOG b/CHANGELOG index d243e1738..cfe53a2bd 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -2,6 +2,7 @@ CHANGELOG Roundcube Webmail =========================== - Fix bug where mail content frame couldn't be reset in some corner cases (#5608) +- Fix regression where groups with email address were resolved to its members' addresses - Fix so group/addressbook selection is retained on page refresh - Fix bug where signature couldn't be added above the quote in Firefox 51 (#5628) diff --git a/program/steps/mail/autocomplete.inc b/program/steps/mail/autocomplete.inc index 0ee007c0d..d4dad09aa 100644 --- a/program/steps/mail/autocomplete.inc +++ b/program/steps/mail/autocomplete.inc @@ -104,6 +104,11 @@ if (!empty($book_types) && strlen($search)) { $contact['display'] = $display; } + // groups with defined email address will not be expanded to its members' addresses + if ($sql_arr['_type'] == 'group') { + $contact['email'] = $email; + } + $contacts[$index] = $contact; $sort_keys[$index] = sprintf('%s %03d', $contact['display'] ?: $name, $idx++);