MCPcopy Index your code
hub / github.com/di-sukharev/opencommit / ensureAsyncIterable

Function ensureAsyncIterable

out/cli.cjs:77978–77993  ·  view source on GitHub ↗
(stream4)

Source from the content-addressed store, hash-verified

77976 controller.close();
77977 } else {
77978 controller.enqueue(value);
77979 }
77980 },
77981 cancel
77982 });
77983}
77984function ensureAsyncIterable(stream4) {
77985 if (isReadableStream4(stream4)) {
77986 makeAsyncIterable2(stream4);
77987 return {
77988 cancel: () => stream4.cancel(),
77989 iterable: stream4
77990 };
77991 } else {
77992 return {
77993 cancel: async () => {
77994 stream4.socket.end();
77995 },
77996 iterable: stream4

Callers 1

createSseStreamFunction · 0.85

Calls 4

isReadableStream4Function · 0.85
makeAsyncIterable2Function · 0.85
endMethod · 0.80
cancelMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…