Skip to content

Commit

Permalink
EWPP-2006: Adapt to container/league 4.x.
Browse files Browse the repository at this point in the history
  • Loading branch information
hernani committed Feb 21, 2022
1 parent db314c9 commit eced1cb
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/TaskRunner.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ private function createConfiguration()
$processor = (new ConfigProcessor())->add($config->export());
$this->config->import($processor->export());
// Keep the container in sync.
$this->container->share('config', $this->config);
$this->container->add('config', $this->config);
}

/**
Expand Down Expand Up @@ -270,10 +270,10 @@ private function createContainer(
) {
$container = Robo::createDefaultContainer($input, $output, $application, $config, $classLoader);
$container->get('commandFactory')->setIncludeAllPublicMethods(false);
$container->share('task_runner.composer', Composer::class)->addArgument($this->workingDir);
$container->share('task_runner.time', Time::class);
$container->share('repository', Repository::class)->addArgument($this->workingDir);
$container->share('filesystem', Filesystem::class);
$container->add('task_runner.composer', Composer::class)->addArgument($this->workingDir);
$container->add('task_runner.time', Time::class);
$container->add('repository', Repository::class)->addArgument($this->workingDir);
$container->add('filesystem', Filesystem::class);

// Add service inflectors.
$container->inflector(ComposerAwareInterface::class)
Expand Down

0 comments on commit eced1cb

Please sign in to comment.