From 596301c10bde5e98b6cfdde51be843ffbf087e8d Mon Sep 17 00:00:00 2001 From: Thomas Bruederli Date: Thu, 14 Nov 2013 20:11:13 +0100 Subject: [PATCH] Reset $part_orig_mimetype variable in for-loop. This avoids attachments along with message/rfc822 parts being listed twice --- program/lib/Roundcube/rcube_message.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/program/lib/Roundcube/rcube_message.php b/program/lib/Roundcube/rcube_message.php index 9b662a286..278007610 100644 --- a/program/lib/Roundcube/rcube_message.php +++ b/program/lib/Roundcube/rcube_message.php @@ -529,8 +529,9 @@ class rcube_message $part_mimetype = $mail_part->real_mimetype; list($primary_type, $secondary_type) = explode('/', $part_mimetype); } - else - $part_mimetype = $mail_part->mimetype; + else { + $part_mimetype = $part_orig_mimetype = $mail_part->mimetype; + } // multipart/alternative if ($primary_type == 'multipart') {