INNER CODE UNIT · TypeScript

onDrain

cloudflare/serverless-registry · push/index.ts:157

                  const onDrain = () => {
                    // Remove event listener when it finishes
                    gzipStream.off("drain", onDrain);
                    res();
                  };

                  gzipStream.on("drain", onDrain);
                  return;
                }

                res();
              });
            },
            async close() {
              // Flush before end
              await new Promise((resFlush) => gzipStream.flush(() => resFlush(true)));
              // End the stream
              await new Promise<void>((res) => gzipStream.end(res));

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…