Skip to content

Commit

Permalink
minor #20666 [FrameworkBundle] mark alias as private during creation …
Browse files Browse the repository at this point in the history
…(xabbuh)

This PR was merged into the 3.1 branch.

Discussion
----------

[FrameworkBundle] mark alias as private during creation

| Q             | A
| ------------- | ---
| Branch?       | 3.1
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #20577 (comment)
| License       | MIT
| Doc PR        | n/a

Commits
-------

828c761 mark alias as private during creation
  • Loading branch information
fabpot committed Nov 29, 2016
2 parents 6459349 + 828c761 commit e4a2c17
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
namespace Symfony\Bundle\FrameworkBundle\DependencyInjection;

use Doctrine\Common\Annotations\Reader;
use Symfony\Component\DependencyInjection\Alias;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\ContainerInterface;
use Symfony\Component\DependencyInjection\Definition;
Expand Down Expand Up @@ -1044,8 +1045,7 @@ private function registerCacheConfiguration(array $config, ContainerBuilder $con

foreach (array('doctrine', 'psr6', 'redis') as $name) {
if (isset($config[$name = 'default_'.$name.'_provider'])) {
$container->setAlias('cache.'.$name, Compiler\CachePoolPass::getServiceProvider($container, $config[$name]));
$container->getAlias('cache.'.$name)->setPublic(false);
$container->setAlias('cache.'.$name, new Alias(Compiler\CachePoolPass::getServiceProvider($container, $config[$name]), false));
}
}
foreach (array('app', 'system') as $name) {
Expand Down

0 comments on commit e4a2c17

Please sign in to comment.