test(web-next): e2e realtime-ping (4 checkpoints)
This commit is contained in:
@@ -55,11 +55,12 @@ export class SocketIORealtimeServer implements IRealtimeServer {
|
||||
// Gate 2: subscribe.
|
||||
socket.on("subscribe", async (requestedName: string, ack?: (r: unknown) => void) => {
|
||||
// Find a registered descriptor whose name (or template) matches requestedName.
|
||||
// listChannels() covers both inbound descriptors and outbound-only channels.
|
||||
let matched: { descriptor: { name: string; scope: unknown }; params: Record<string, string> } | null = null;
|
||||
for (const entry of registry.list()) {
|
||||
const m = matchChannelTemplate(entry.descriptor.name, requestedName);
|
||||
for (const descriptor of registry.listChannels()) {
|
||||
const m = matchChannelTemplate(descriptor.name, requestedName);
|
||||
if (m) {
|
||||
matched = { descriptor: entry.descriptor, params: m.params };
|
||||
matched = { descriptor, params: m.params };
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user