MCPcopy
hub / github.com/angular/angular / assertNotDestroyed

Function assertNotDestroyed

packages/core/src/di/r3_injector.ts:683–690  ·  view source on GitHub ↗
(injector: R3Injector)

Source from the content-addressed store, hash-verified

681}
682
683export function assertNotDestroyed(injector: R3Injector): void {
684 if (injector.destroyed) {
685 throw new RuntimeError(
686 RuntimeErrorCode.INJECTOR_ALREADY_DESTROYED,
687 ngDevMode && 'Injector has already been destroyed.',
688 );
689 }
690}
691
692function makeRecord<T>(
693 factory: (() => T) | undefined,

Callers 5

runInInjectionContextFunction · 0.90
destroyMethod · 0.85
onDestroyMethod · 0.85
runInContextMethod · 0.85
getMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…