MCPcopy
hub / github.com/angular/angular / onUnhandledRejection

Method onUnhandledRejection

packages/service-worker/worker/src/driver.ts:365–372  ·  view source on GitHub ↗
(event: PromiseRejectionEvent)

Source from the content-addressed store, hash-verified

363 }
364
365 private onUnhandledRejection(event: PromiseRejectionEvent): void {
366 // Handle unhandled promise rejections in the service worker.
367 // This is for debugging and preventing silent failures.
368 this.debugger.log(
369 `Unhandled promise rejection occurred`,
370 `Driver.onUnhandledRejection(reason: ${event.reason})`,
371 );
372 }
373
374 private async ensureInitialized(event: ExtendableEvent): Promise<void> {
375 // Since the SW may have just been started, it may or may not have been initialized already.

Callers 1

constructorMethod · 0.95

Calls 1

logMethod · 0.65

Tested by

no test coverage detected