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

[5.3] Always return a container instance from Container::getInstance() #13111

Merged
merged 4 commits into from
Apr 11, 2016

Conversation

JosephSilber
Copy link
Member

Currently, if you haven't set a singleton manually, Container::getInstance() returns null, even though the docblock says it always returns static.

After this patch, Container::getInstance() always returns an instance of the container; if no singleton has been set, it's set now.

@taylorotwell taylorotwell merged commit 2779f7b into laravel:master Apr 11, 2016
@JosephSilber JosephSilber deleted the container-singleton branch April 11, 2016 14:39
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 this pull request may close these issues.

2 participants