Skip to content

Commit

Permalink
refactor(sio): make Namespace._fns private (#5196)
Browse files Browse the repository at this point in the history
Related: #5179
  • Loading branch information
ammut authored Oct 23, 2024
1 parent 029e010 commit aead835
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/socket.io/lib/namespace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ export class Namespace<
SocketData
>;

protected _fns: Array<
private _fns: Array<
(
socket: Socket<ListenEvents, EmitEvents, ServerSideEvents, SocketData>,
next: (err?: ExtendedError) => void,
Expand Down
2 changes: 1 addition & 1 deletion packages/socket.io/lib/parent-namespace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export class ParentNamespace<
): Namespace<ListenEvents, EmitEvents, ServerSideEvents, SocketData> {
debug("creating child namespace %s", name);
const namespace = new Namespace(this.server, name);
this._fns.forEach((fn) => namespace.use(fn));
this["_fns"].forEach((fn) => namespace.use(fn));
this.listeners("connect").forEach((listener) =>
namespace.on("connect", listener),
);
Expand Down

0 comments on commit aead835

Please sign in to comment.