Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UnityDependencyResolver.GetInstances<T>() GetInstances does not return all registered instances #36

Open
kentcooper opened this issue Sep 26, 2014 · 1 comment · May be fixed by #37
Open

Comments

@kentcooper
Copy link

Because the UnityDependencyResolver.GetInstances() method is using the ResolveAll() method of Unity it will not return any unnamed instances that were registered in the Unity container. I'm not sure if this is intentional since this is the default behavior for Unity, however it did cause me some confusion when I ran into it.

If this is not intentional I have a fix I implemented and can do a pull request to resolve it.

Thanks,
Kent

@mhinze
Copy link
Owner

mhinze commented Sep 27, 2014

PR would be awesome. Thanks

On Fri, Sep 26, 2014 at 10:09 AM, kentcooper [email protected]
wrote:

Because the UnityDependencyResolver.GetInstances() method is using the
ResolveAll() method of Unity it will not return any unnamed instances that
were registered in the Unity container. I'm not sure if this is intentional
since this is the default behavior for Unity, however it did cause me some
confusion when I ran into it.

If this is not intentional I have a fix I implemented and can do a pull
request to resolve it.

Thanks,
Kent


Reply to this email directly or view it on GitHub
#36.

@kentcooper kentcooper linked a pull request Sep 29, 2014 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants