Skip to content

Commit ac3df29

Browse files
committed
fix: correctly set current socket connection after a reconnect
1 parent 7982e94 commit ac3df29

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/client.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ export class WmClient {
412412
// Attempt to reconnect if not manually closed.
413413
if (!this._isManuallyClosed) {
414414
setTimeout(
415-
() => this._socketPromise === this._createSocket(),
415+
() => (this._socketPromise = this._createSocket()),
416416
this._options?.reconnectInterval ??
417417
this.DEFAULT_RECONNECT_INTERVAL,
418418
);

0 commit comments

Comments
 (0)