Skip to content

Conversation

@seriquynh
Copy link
Contributor

  • Container::resolvePrimitive() or Container::resolveClass() may throws BindingResolutionException.
  • Container::resolveDependencies() calls Container::resolvePrimitive() or Container::resolveClass() without try-catch block.
  • Container::build() calls Container::resolveDependencies() without try-catch block.
  • Container::resolve() calls Container::build() without try-catch block.
  • Container::make() directly calls Container::resolve().

@taylorotwell taylorotwell merged commit d4de66f into laravel:master Dec 15, 2018
@seriquynh seriquynh deleted the fix_container_docblock branch December 16, 2018 10:12
* @param array $parameters
* @return mixed
*
* @throws \Illuminate\Contracts\Container\BindingResolutionException
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@XuanQuynh This should be added to the Container interface docblock too, right? :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@X-Coder264 I agree with you but it's a breaking change. I am not sure Mr.Otwell want to add it to the Container interface. Someone may do that.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@XuanQuynh From a purely theoretical standpoint, yes. But realistically looking the exception in question is in the contracts namespace which means that at least some method from the contract is supposed to throw it (otherwise it wouldn't exist there in the first place). Besides you did send this PR to the master (5.8) branch which is precisely the branch where you send breaking changes so I don't see a problem :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@X-Coder264 Ok. I will create a new pull request soon and reference it with this. :)

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.

3 participants