public function saveAttachments($mail)
    {
        /** @var \Shockwavemk\Mail\Base\Model\Mail\Attachment[] $attachments */
        $attachments = $mail->getAttachments();

        foreach ($attachments as $attachment) {
            $this->saveAttachment($attachment);
        }

        return $this;
    }
public function saveAttachments($mail)
    {
        /** @var \Shockwavemk\Mail\Base\Model\Mail\Attachment[] $attachments */
        $attachments = $mail->getAttachments();

        foreach ($attachments as $attachment) {
            $this->saveAttachment($attachment);
        }

        return $this;
    }
public function saveAttachments ( $ mail ) { /** @var \Shockwavemk\Mail\Base\Model\Mail\Attachment[] $attachments */ $ attachments = $ mail -> getAttachments ( ) ; foreach ( $ attachments as $ attachment ) { $ this -> saveAttachment ( $ attachment ) ; } return $ this ; }
Save all attachments of a given mail

@param \Shockwavemk\Mail\Base\Model\Mail $mail
@return $this
@throws \Magento\Framework\Exception\FileSystemException
@throws \Magento\Framework\Exception\MailException
@throws \Exception
Save all attachments of a given mail