-
Notifications
You must be signed in to change notification settings - Fork 60
Closed
Description
At least in AngularJs, the following condition may be true even though the $injector found the injectible - leading to an exception where there shouldn't be one.
core/src/resolve/resolveContext.ts
Lines 176 to 179 in 215cafc
let fromInjector = this.injector().getNative(token); | |
if (!fromInjector) { | |
throw new Error("Could not find Dependency Injection token: " + stringify(token)); | |
} |
For example:
angular.module(x).constant('iCanBeInjectedAndShouldNotThrow', false)