ContactAttachment icon indicating copy to clipboard operation
ContactAttachment copied to clipboard

TransportBuilder file - Mime type and CC problem

Open CUTTRHOAT69 opened this issue 1 year ago • 0 comments

The File Rewrite/Magento/Framework/Mail/Template/TransportBuilder.php that rewrite the Magento TransportBuilder has some issues.

Magento version: 2.4.5-p1

  1. The Mime type is not being sent to the email; As can be seen on the diff screenshot (Magento file on the left), the creation of the mime type got some changes and the part that creates the mime type is not being used image
$mimePart = $this->mimePartInterfaceFactory->create(['content' => $content]);
$parts = count($this->attachments) ? array_merge([$mimePart], $this->attachments) : [$mimePart];

The first line, is only creating the object with the content, it's missing the type information that was supposed to be $part['type']

  1. Emails are being sent without the CC emails on it; I'm not sure why, but an else statement has been removed from the function addAddressByType on the rewrite, that may be the reason to have this issue, as can be seen on the diff screenshot (Magento file on the left): image

CUTTRHOAT69 avatar Sep 11 '24 14:09 CUTTRHOAT69