Skip to content

Commit

Permalink
Update connection.js
Browse files Browse the repository at this point in the history
  • Loading branch information
wackfx authored Nov 24, 2023
1 parent 61c4d5b commit 233945a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/connection.js
Original file line number Diff line number Diff line change
Expand Up @@ -429,10 +429,9 @@ function Connection(options, queues = {}, { onopen = noop, onend = noop, onclose
lifeTimer.cancel()
connectTimer.cancel()

if (socket.encrypted) {
if (socket.encrypted)
socket.removeAllListeners()
socket = null
}
socket = null

if (initial)
return reconnect()
Expand Down

0 comments on commit 233945a

Please sign in to comment.