Skip to content

Commit 736c2cf

Browse files
committed
Support binary attachments with Base64 encoding
1 parent dd46bed commit 736c2cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/EmailitTransport.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ protected function getAttachments(RawMessage $message): array
8888
foreach ($message->getAttachments() as $attachment) {
8989
$attachments[] = [
9090
'filename' => $attachment->getPreparedHeaders()->get('content-disposition')?->getParameter('filename'),
91-
'content' => $attachment->getBody(),
91+
'content' => base64_encode($attachment->getBody()),
9292
'content_type' => $attachment->getMediaType(),
9393
];
9494
}

0 commit comments

Comments
 (0)