MCPcopy
hub / github.com/socketio/socket.io / callback

Method callback

packages/engine.io/lib/transports/polling.ts:191–199  ·  view source on GitHub ↗
(packet)

Source from the content-addressed store, hash-verified

189 override onData(data: RawData) {
190 debug('received "%s"', data);
191 const callback = (packet) => {
192 if ("close" === packet.type) {
193 debug("got xhr close packet");
194 this.onClose();
195 return false;
196 }
197
198 this.onPacket(packet);
199 };
200
201 if (this.protocol === 3) {
202 (this.parser as typeof parser_v3).decodePayload(data, callback);

Callers

nothing calls this directly

Calls 3

onCloseMethod · 0.95
debugFunction · 0.85
onPacketMethod · 0.45

Tested by

no test coverage detected