SMTPConnection only calls the connect() callback once the handshake succeeds; a refused or timed out connection is emitted as an 'error' event, which was only logged. relay() then never settled, so its finally block (which now releases the email stream) never ran, auto-relay held the incoming SMTP transaction open without a reply, and the REST relay request hung. Reject the connect promise from the 'error' handler.
296 B
296 B
@maildev/smtp, maildev
| @maildev/smtp | maildev |
|---|---|
| patch | patch |
Fail the relay when the outgoing server cannot be reached. The connection error was only logged, so the relay never finished: with auto-relay on, the SMTP client sending to MailDev never got its reply, and the manual relay request never answered.