mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-01 14:38:47 +02:00
N°8910 - Upgrade Symfony packages (#811)
This commit is contained in:
@@ -53,14 +53,21 @@ EOF
|
||||
protected function execute(InputInterface $input, OutputInterface $output): int
|
||||
{
|
||||
$io = new SymfonyStyle($input, $output);
|
||||
$exitCode = Command::SUCCESS;
|
||||
|
||||
foreach ($this->pools as $name => $pool) {
|
||||
$io->comment(\sprintf('Pruning cache pool: <info>%s</info>', $name));
|
||||
$pool->prune();
|
||||
|
||||
if (!$pool->prune()) {
|
||||
$io->error(\sprintf('Cache pool "%s" could not be pruned.', $name));
|
||||
$exitCode = Command::FAILURE;
|
||||
}
|
||||
}
|
||||
|
||||
$io->success('Successfully pruned cache pool(s).');
|
||||
if (Command::SUCCESS === $exitCode) {
|
||||
$io->success('Successfully pruned cache pool(s).');
|
||||
}
|
||||
|
||||
return 0;
|
||||
return $exitCode;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -161,7 +161,7 @@ EOF
|
||||
$steps = explode('.', $path);
|
||||
|
||||
foreach ($steps as $step) {
|
||||
if (!\array_key_exists($step, $config)) {
|
||||
if (!\is_array($config) || !\array_key_exists($step, $config)) {
|
||||
throw new LogicException(\sprintf('Unable to find configuration for "%s.%s".', $alias, $path));
|
||||
}
|
||||
|
||||
|
||||
@@ -61,14 +61,13 @@ EOF
|
||||
}
|
||||
|
||||
foreach ($this->vault->list(true) as $name => $value) {
|
||||
$localValue = $this->localVault->reveal($name);
|
||||
if (null === $localValue = $this->localVault->reveal($name)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
if (null !== $localValue && $value !== $localValue) {
|
||||
if ($value !== $localValue) {
|
||||
$this->vault->seal($name, $localValue);
|
||||
} elseif (null !== $message = $this->localVault->getLastMessage()) {
|
||||
$io->error($message);
|
||||
|
||||
return 1;
|
||||
$io->note($this->vault->getLastMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user