From 13a872233cc7fc6235a4b5a9fc15e6cf485af9cb Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Mon, 15 Mar 2010 13:51:17 -0600 Subject: [PATCH] Ignore Reply-List address if it is the same as To/Reply-To --- imp/lib/Compose.php | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/imp/lib/Compose.php b/imp/lib/Compose.php index 28af5ffa8..d11504a95 100644 --- a/imp/lib/Compose.php +++ b/imp/lib/Compose.php @@ -1349,12 +1349,16 @@ class IMP_Compose } if (!is_null($list_info) && !empty($list_info['reply_list'])) { - $header['to'] = $list_info['reply_list']; + /* If To/Reply-To and List-Reply address are the same, no need + * to handle these address separately. */ + if (Horde_Mime_Address::bareAddress($list_info['reply_list']) != Horde_Mime_Address::bareAddress($header['to'])) { + $header['to'] = $list_info['reply_list']; + $reply_type = 'reply_list'; + } + if ($type == '*') { $all_headers['reply_list'] = $header; } - - $reply_type = 'reply_list'; } elseif (in_array($type, array('reply_all', 'reply_auto', '*'))) { /* Clear the To field if we are auto-determining addresses. */ if ($type == 'reply_auto') { -- 2.11.0