remove redundant state from smtp

This commit is contained in:
holger krekel
2019-12-08 01:13:34 +01:00
parent a8e9a1fbe5
commit 93e8cca02f
3 changed files with 12 additions and 19 deletions

View File

@@ -203,8 +203,8 @@ impl Job {
match task::block_on(smtp.send(context, recipients_list, body, self.job_id)) {
Err(crate::smtp::send::Error::SendError(err)) => {
// Remote error, retry later.
smtp.disconnect();
info!(context, "SMTP failed to send: {}", err);
smtp.disconnect();
self.try_again_later(TryAgain::AtOnce, Some(err.to_string()));
}
Err(crate::smtp::send::Error::EnvelopeError(err)) => {