Skip to content
This repository has been archived by the owner on Nov 17, 2021. It is now read-only.

Commit

Permalink
added previous exception to exception
Browse files Browse the repository at this point in the history
  • Loading branch information
fabpot committed Sep 11, 2018
1 parent 5a6992d commit 2ea9f8c
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions lib/classes/Swift/Transport/AbstractSmtpTransport.php
Expand Up @@ -188,10 +188,7 @@ public function send(Swift_Mime_SimpleMessage $message, &$failedRecipients = nul
}

if (!$reversePath = $this->getReversePath($message)) {
$this->throwException(new Swift_TransportException(
'Cannot send message without a sender address'
)
);
$this->throwException(new Swift_TransportException('Cannot send message without a sender address'));
}

$to = (array) $message->getTo();
Expand Down Expand Up @@ -472,10 +469,7 @@ protected function getFullResponse($seq)
} catch (Swift_TransportException $e) {
$this->throwException($e);
} catch (Swift_IoException $e) {
$this->throwException(
new Swift_TransportException(
$e->getMessage())
);
$this->throwException(new Swift_TransportException($e->getMessage(), 0, $e));
}

return $response;
Expand Down

0 comments on commit 2ea9f8c

Please sign in to comment.