Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit a86bf52

Browse filesBrowse files
pjarmalaviciusRobin Chalas
authored and
Robin Chalas
committed
[SecurityBundle] resolve class name parameter inside AddSecurityVotersPass
1 parent eeaea83 commit a86bf52
Copy full SHA for a86bf52

File tree

1 file changed

+2
-1
lines changed
Filter options

1 file changed

+2
-1
lines changed

‎src/Symfony/Bundle/SecurityBundle/DependencyInjection/Compiler/AddSecurityVotersPass.php

Copy file name to clipboardExpand all lines: src/Symfony/Bundle/SecurityBundle/DependencyInjection/Compiler/AddSecurityVotersPass.php
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ public function process(ContainerBuilder $container)
4242
}
4343

4444
foreach ($voters as $voter) {
45-
$class = $container->getDefinition((string) $voter)->getClass();
45+
$definition = $container->getDefinition((string) $voter);
46+
$class = $container->getParameterBag()->resolveValue($definition->getClass());
4647

4748
if (!is_a($class, VoterInterface::class, true)) {
4849
@trigger_error(sprintf('Using a security.voter tag on a class without implementing the %1$s is deprecated as of 3.4 and will be removed in 4.0. Implement the %1$s instead.', VoterInterface::class), E_USER_DEPRECATED);

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.