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

has() method doesn't look at $resolved values #16

Closed
renakdup opened this issue Aug 20, 2024 · 0 comments
Closed

has() method doesn't look at $resolved values #16

renakdup opened this issue Aug 20, 2024 · 0 comments
Assignees
Labels
bug Something isn't working question Further information is requested

Comments

@renakdup
Copy link
Owner

When we get an object via $c->get('service-name'), it create an object and put it into $resolved property of the container.
Then if we check service existing via $c->has('service-name'), it returns false.

image
The same container object doesn't exists in the container services.

Example of code that would not make sense:
$foo = $container->has('foo') ? $container->get('foo') : null;

Question:
Should we check when run $c->has(...) that service exists in $resolved property?

@renakdup renakdup self-assigned this Aug 20, 2024
@renakdup renakdup added bug Something isn't working question Further information is requested labels Aug 20, 2024
renakdup added a commit that referenced this issue Aug 20, 2024
#16 has() method doesn't look at $resolved values
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant