MCPcopy Index your code
hub / github.com/getsentry/sentry-javascript / getOriginalWaitUntil

Function getOriginalWaitUntil

packages/cloudflare/src/flush.ts:36–41  ·  view source on GitHub ↗
(context: ExecutionContext)

Source from the content-addressed store, hash-verified

34 * By using the original waitUntil for flush operations, we bypass this issue.
35 */
36export function getOriginalWaitUntil(context: ExecutionContext): ExecutionContext['waitUntil'] | undefined {
37 // eslint-disable-next-line @typescript-eslint/unbound-method
38 const currentWaitUntil = context.waitUntil;
39 const original = flushLockRegistries.get(currentWaitUntil)?.originalWaitUntil;
40 return original ?? currentWaitUntil;
41}
42
43/**
44 * Enhances the given execution context by wrapping its `waitUntil` method with a proxy

Callers 2

flush.test.tsFile · 0.90
wrapRequestHandlerFunction · 0.90

Calls 1

getMethod · 0.65

Tested by

no test coverage detected