@ -241,10 +241,10 @@ export class NodeInjectorFactory {
|
||||
}
|
||||
}
|
||||
|
||||
const FactoryPrototype = NodeInjectorFactory.prototype;
|
||||
export function isFactory(obj: any): obj is NodeInjectorFactory {
|
||||
// See: https://jsperf.com/instanceof-vs-getprototypeof
|
||||
return obj !== null && typeof obj == 'object' && Object.getPrototypeOf(obj) == FactoryPrototype;
|
||||
return obj !== null && typeof obj == 'object' &&
|
||||
Object.getPrototypeOf(obj) == NodeInjectorFactory.prototype;
|
||||
}
|
||||
|
||||
// Note: This hack is necessary so we don't erroneously get a circular dependency
|
||||
|
Reference in New Issue
Block a user