mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-28 04: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:
@@ -22,7 +22,7 @@ class ParametersConfigurator extends AbstractConfigurator
|
||||
{
|
||||
public const FACTORY = 'parameters';
|
||||
|
||||
private $container;
|
||||
private ContainerBuilder $container;
|
||||
|
||||
public function __construct(ContainerBuilder $container)
|
||||
{
|
||||
@@ -30,11 +30,9 @@ class ParametersConfigurator extends AbstractConfigurator
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a parameter.
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
final public function set(string $name, $value): self
|
||||
final public function set(string $name, mixed $value): static
|
||||
{
|
||||
if ($value instanceof Expression) {
|
||||
throw new InvalidArgumentException(sprintf('Using an expression in parameter "%s" is not allowed.', $name));
|
||||
@@ -46,11 +44,9 @@ class ParametersConfigurator extends AbstractConfigurator
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates a parameter.
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
final public function __invoke(string $name, $value): self
|
||||
final public function __invoke(string $name, mixed $value): static
|
||||
{
|
||||
return $this->set($name, $value);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user