Skip to content

Commit bbf974a

Browse files
author
Albin Kerouaton
committed
Fix default cache alias when no provider defined
1 parent b6943d4 commit bbf974a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/DependencyInjection/CacheAdapterExtension.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,9 @@ public function load(array $configs, ContainerBuilder $container)
5757
$def->addTag('cache.provider');
5858
}
5959

60-
$container->setAlias('cache', 'cache.provider.'.$first);
60+
if ($first !== null) {
61+
$container->setAlias('cache', 'cache.provider.'.$first);
62+
}
6163
}
6264

6365
/**

0 commit comments

Comments
 (0)