You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Binding objects implementing IInitializable or IDisposable makes them initialized/disposed by the kernel. Binding a decorator via Container.Decorate<TContract>().With<TDecorator>() decorates an already bound object. But binding a decorator which implements any of the former interfaces will not register them to the corresponding manager of the kernel.
To Reproduce
Bind a type via an interface. Then on top of that interface bind a decorator which implements IInitializable or IDisposable.
Expected behavior
Expected Initialize() and Dispose() methods of the decorator to be invoked, but these are not invoked, even if other methods implemented by the interface is properly decorated.
Extenject and Unity info (please complete the following information):
Describe the bug
Binding objects implementing
IInitializable
orIDisposable
makes them initialized/disposed by the kernel. Binding a decorator viaContainer.Decorate<TContract>().With<TDecorator>()
decorates an already bound object. But binding a decorator which implements any of the former interfaces will not register them to the corresponding manager of the kernel.To Reproduce
Bind a type via an interface. Then on top of that interface bind a decorator which implements
IInitializable
orIDisposable
.Expected behavior
Expected
Initialize()
andDispose()
methods of the decorator to be invoked, but these are not invoked, even if other methods implemented by the interface is properly decorated.Extenject and Unity info (please complete the following information):
The text was updated successfully, but these errors were encountered: