From 96f084e9cf30fe714efd4ffd5ac6216b4d773d74 Mon Sep 17 00:00:00 2001 From: Thomas Bruederli <thomas@roundcube.net> Date: Mon, 18 Aug 2014 08:17:16 -0400 Subject: [PATCH] Don't expand recipient groups if they have an email address --- program/steps/mail/autocomplete.inc | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/program/steps/mail/autocomplete.inc b/program/steps/mail/autocomplete.inc index c805cd0..30b8f22 100644 --- a/program/steps/mail/autocomplete.inc +++ b/program/steps/mail/autocomplete.inc @@ -124,7 +124,13 @@ if ($group_prop['email']) { $idx = 0; foreach ((array)$group_prop['email'] as $email) { - $contacts[] = array('name' => format_email_recipient($email, $group['name']), 'type' => 'group'); + $contacts[] = array( + 'name' => format_email_recipient($email, $group['name']), + 'email' => $email, + 'type' => 'group', + 'id' => $group['ID'], + 'source' => $id, + ); $sort_keys[] = sprintf('%s %03d', $group['name'] , $idx++); if (count($contacts) >= $MAXNUM) { -- Gitblit v1.9.1