diff --git a/src/imap.js b/src/imap.js index d26f92e..1268b91 100644 --- a/src/imap.js +++ b/src/imap.js @@ -550,7 +550,7 @@ export default class Imap { */ // if (command[0] === ASCII_PLUS) { - if (this._currentCommand.data.length) { + if (this._currentCommand.data?.length) { // feed the next chunk of data var chunk = this._currentCommand.data.shift() chunk += (!this._currentCommand.data.length ? EOL : '') // EOL if there's nothing more to send