From 1b42a6116a76bf8fc8a9cf9a0421b53c659a5e98 Mon Sep 17 00:00:00 2001 From: Andris Reinman Date: Tue, 28 Jan 2025 20:17:03 +0200 Subject: [PATCH] fix(connection-failure): Reject all pending commands, not just LOGOUT --- lib/imap-flow.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/imap-flow.js b/lib/imap-flow.js index b3a66cf..be38068 100644 --- a/lib/imap-flow.js +++ b/lib/imap-flow.js @@ -1583,7 +1583,7 @@ class ImapFlow extends EventEmitter { // reject command that is currently processed if (this.currentRequest && this.requestTagMap.has(this.currentRequest.tag)) { let request = this.requestTagMap.get(this.currentRequest.tag); - if (request && ['LOGOUT'].includes(request.command)) { + if (request) { this.requestTagMap.delete(request.tag); const error = new Error('Connection not available'); error.code = 'NoConnection';