Skip to content

Commit 2bbff54

Browse files
fix(core) lookup enhancers on providers
1 parent f0d0ded commit 2bbff54

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

packages/core/injector/module.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,9 @@ export class Module {
192192
this._injectables.set(injectable.name, instanceWrapper);
193193

194194
if (host) {
195-
const hostWrapper = this._controllers.get(host && host.name);
195+
const token = host && host.name;
196+
const hostWrapper =
197+
this._controllers.get(host && host.name) || this._providers.get(token);
196198
hostWrapper && hostWrapper.addEnhancerMetadata(instanceWrapper);
197199
}
198200
}

0 commit comments

Comments
 (0)