mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-30 05:58:46 +02:00
N°6934 - Symfony 6.4 - upgrade Symfony bundles to 6.4 (#580)
* Update Symfony lib to version ~6.4.0 * Update code missing return type * Add an iTop general configuration entry to store application secret (Symfony mandatory parameter) * Use dependency injection in ExceptionListener & UserProvider classes
This commit is contained in:
@@ -14,6 +14,7 @@ namespace Symfony\Component\DependencyInjection\Compiler;
|
||||
use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
use Symfony\Component\DependencyInjection\Definition;
|
||||
use Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException;
|
||||
use Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface;
|
||||
|
||||
/**
|
||||
* Resolves all parameter placeholders "%somevalue%" to their real values.
|
||||
@@ -22,18 +23,18 @@ use Symfony\Component\DependencyInjection\Exception\ParameterNotFoundException;
|
||||
*/
|
||||
class ResolveParameterPlaceHoldersPass extends AbstractRecursivePass
|
||||
{
|
||||
private $bag;
|
||||
private $resolveArrays;
|
||||
private $throwOnResolveException;
|
||||
protected bool $skipScalars = false;
|
||||
|
||||
public function __construct($resolveArrays = true, $throwOnResolveException = true)
|
||||
{
|
||||
$this->resolveArrays = $resolveArrays;
|
||||
$this->throwOnResolveException = $throwOnResolveException;
|
||||
private ParameterBagInterface $bag;
|
||||
|
||||
public function __construct(
|
||||
private bool $resolveArrays = true,
|
||||
private bool $throwOnResolveException = true,
|
||||
) {
|
||||
}
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
* @return void
|
||||
*
|
||||
* @throws ParameterNotFoundException
|
||||
*/
|
||||
@@ -57,10 +58,10 @@ class ResolveParameterPlaceHoldersPass extends AbstractRecursivePass
|
||||
}
|
||||
|
||||
$this->bag->resolve();
|
||||
$this->bag = null;
|
||||
unset($this->bag);
|
||||
}
|
||||
|
||||
protected function processValue($value, bool $isRoot = false)
|
||||
protected function processValue(mixed $value, bool $isRoot = false): mixed
|
||||
{
|
||||
if (\is_string($value)) {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user