Skip to content

Commit e1ad89a

Browse files
backendsurajdarrachequesne
authored andcommitted
Drain queue before emitting connect event
1 parent cdae019 commit e1ad89a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/socket.io-client/lib/socket.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -834,8 +834,8 @@ export class Socket<
834834
this._pid = pid; // defined only if connection state recovery is enabled
835835
this.connected = true;
836836
this.emitBuffered();
837-
this.emitReserved("connect");
838837
this._drainQueue(true);
838+
this.emitReserved("connect");
839839
}
840840

841841
/**

0 commit comments

Comments
 (0)