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

Fix name and phpdoc of ContainerBuilder::removeBindings #31173

Merged
merged 1 commit into from Apr 27, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -1527,13 +1527,13 @@ public function getRemovedBindingIds()
}

/**
* Adds a removed binding id.
* Removes bindings for a service.
*
* @param int $id
* @param string $id The service identifier
*
* @internal
*/
public function addRemovedBindingIds($id)
public function removeBindings($id)
{
if ($this->hasDefinition($id)) {
foreach ($this->getDefinition($id)->getBindings() as $key => $binding) {
Expand Down
Expand Up @@ -59,7 +59,7 @@ public function __destruct()
{
parent::__destruct();

$this->container->addRemovedBindingIds($this->id);
$this->container->removeBindings($this->id);

if (!$this->definition instanceof ChildDefinition) {
$this->container->setDefinition($this->id, $this->definition->setInstanceofConditionals($this->instanceof));
Expand Down
Expand Up @@ -91,7 +91,7 @@ public function registerClasses(Definition $prototype, $namespace, $resource, $e
*/
protected function setDefinition($id, Definition $definition)
{
$this->container->addRemovedBindingIds($id);
$this->container->removeBindings($id);

if ($this->isLoadingInstanceof) {
if (!$definition instanceof ChildDefinition) {
Expand Down