Skip to content

Commit

Permalink
Fix _storeProcessing staying true after outStore got emptied
Browse files Browse the repository at this point in the history
  • Loading branch information
janwillem-penterman committed Jun 8, 2022
1 parent 5c04ab4 commit 463c023
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/client.js
Original file line number Diff line number Diff line change
Expand Up @@ -1806,7 +1806,6 @@ MqttClient.prototype._onConnect = function (packet) {
if (!outStore) {
return
}
that._storeProcessing = true

const packet = outStore.read(1)

Expand All @@ -1818,6 +1817,8 @@ MqttClient.prototype._onConnect = function (packet) {
return
}

that._storeProcessing = true

// Skip already processed store packets
if (that._packetIdsDuringStoreProcessing[packet.messageId]) {
storeDeliver()
Expand Down

0 comments on commit 463c023

Please sign in to comment.