diff --git a/Transport/Smtp/SmtpTransport.php b/Transport/Smtp/SmtpTransport.php index 0de38fb..7de2f91 100644 --- a/Transport/Smtp/SmtpTransport.php +++ b/Transport/Smtp/SmtpTransport.php @@ -205,11 +205,11 @@ protected function doSend(SentMessage $message): void $this->ping(); } - if (!$this->started) { - $this->start(); - } - try { + if (!$this->started) { + $this->start(); + } + $envelope = $message->getEnvelope(); $this->doMailFromCommand($envelope->getSender()->getEncodedAddress()); foreach ($envelope->getRecipients() as $recipient) {