add attachment emails support

This commit is contained in:
Viacheslav Sychov 2014-08-15 17:55:19 +03:00
parent 766db0ad3a
commit de108c0e86

View File

@ -444,7 +444,9 @@ class Message
{
$parameters = self::getParametersFromStructure($structure);
if (isset($parameters['name']) || isset($parameters['filename'])) {
if ((isset($parameters['name']) || isset($parameters['filename']))
|| (isset($structure->subtype) && strtolower($structure->subtype) == 'rfc822')
) {
$attachment = new Attachment($this, $structure, $partIdentifier);
$this->attachments[] = $attachment;
} elseif ($structure->type == 0 || $structure->type == 1) {