mirror of
https://github.com/Combodo/iTop.git
synced 2026-04-23 18:48:51 +02:00
Re-dump autoloader and composer.lock
This commit is contained in:
@@ -39,11 +39,11 @@ class ExpressionLanguageProvider implements ExpressionFunctionProviderInterface
|
||||
public function getFunctions(): array
|
||||
{
|
||||
return [
|
||||
new ExpressionFunction('service', $this->serviceCompiler ?? fn ($arg) => sprintf('$container->get(%s)', $arg), fn (array $variables, $value) => $variables['container']->get($value)),
|
||||
new ExpressionFunction('service', $this->serviceCompiler ?? fn ($arg) => \sprintf('$container->get(%s)', $arg), fn (array $variables, $value) => $variables['container']->get($value)),
|
||||
|
||||
new ExpressionFunction('parameter', fn ($arg) => sprintf('$container->getParameter(%s)', $arg), fn (array $variables, $value) => $variables['container']->getParameter($value)),
|
||||
new ExpressionFunction('parameter', fn ($arg) => \sprintf('$container->getParameter(%s)', $arg), fn (array $variables, $value) => $variables['container']->getParameter($value)),
|
||||
|
||||
new ExpressionFunction('env', fn ($arg) => sprintf('$container->getEnv(%s)', $arg), function (array $variables, $value) {
|
||||
new ExpressionFunction('env', fn ($arg) => \sprintf('$container->getEnv(%s)', $arg), function (array $variables, $value) {
|
||||
if (!$this->getEnv) {
|
||||
throw new LogicException('You need to pass a getEnv closure to the expression language provider to use the "env" function.');
|
||||
}
|
||||
@@ -51,7 +51,7 @@ class ExpressionLanguageProvider implements ExpressionFunctionProviderInterface
|
||||
return ($this->getEnv)($value);
|
||||
}),
|
||||
|
||||
new ExpressionFunction('arg', fn ($arg) => sprintf('$args?->get(%s)', $arg), fn (array $variables, $value) => $variables['args']?->get($value)),
|
||||
new ExpressionFunction('arg', fn ($arg) => \sprintf('$args?->get(%s)', $arg), fn (array $variables, $value) => $variables['args']?->get($value)),
|
||||
];
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user