diff --git a/webui/system/helper/mime.php b/webui/system/helper/mime.php index 4eeb1f2..428c118 100644 --- a/webui/system/helper/mime.php +++ b/webui/system/helper/mime.php @@ -138,6 +138,10 @@ if(!isset($headers['content-type'])) { $headers['content-type'] = 'text/plain'; } + // I saw a dumb email (it was a spam, though) having two Date: lines. + // In this case we take the first date, and discard the rest + if(is_array($headers[self::HEADER_FIELDS[4]])) { $headers[self::HEADER_FIELDS[4]] = $headers[self::HEADER_FIELDS[4]][0]; } + for($i=0; $i