Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions Model/TransportBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@

namespace Adyen\Payment\Model;

use Laminas\Mime\Mime;
use Magento\Framework\App\TemplateTypesInterface;
use Magento\Framework\Exception\LocalizedException;
use Magento\Framework\Exception\MailException;
Expand Down Expand Up @@ -424,12 +423,9 @@ private function prepareAttachmentPart($content, $filename)
return $this->mimePartInterfaceFactory->create(
[
'content' => $content,
// @phpstan-ignore-next-line
'type' => Mime::TYPE_OCTETSTREAM,
// @phpstan-ignore-next-line
'disposition' => Mime::DISPOSITION_ATTACHMENT,
// @phpstan-ignore-next-line
'encoding' => Mime::ENCODING_BASE64,
'type' => MimeInterface::TYPE_OCTET_STREAM,
'disposition' => MimeInterface::DISPOSITION_ATTACHMENT,
'encoding' => MimeInterface::ENCODING_BASE64,
'fileName' => $filename
]
);
Expand Down
4 changes: 0 additions & 4 deletions Test/Unit/Model/TransportBuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,6 @@ public function testGetTransportBuildsMessageWithAddressesAndResetsState(): void
*/
public function testGetTransportAddsAttachmentParts(): void
{
if (!class_exists(\Laminas\Mime\Mime::class)) {
$this->markTestSkipped('Skipping attachment test: laminas/laminas-mime is not installed in this environment.');
}

$this->prepareTemplateMock(
TemplateTypesInterface::TYPE_TEXT,
'Hello',
Expand Down
Loading