bug #4722 use getShareDir as an indicator of Symfony version (tacman)

This PR was squashed before being merged into the 3.x branch.

Discussion
----------

use getShareDir as an indicator of Symfony version

Proposal to fix #4719 , replaces #4721

Commits
-------

c4dcd0bb8c use getShareDir as an indicator of Symfony version
This commit is contained in:
Fabien Potencier
2025-12-05 09:51:55 +01:00
+2 -1
View File
@@ -13,9 +13,10 @@ namespace Twig\Extra\TwigExtraBundle;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Symfony\Component\HttpKernel\KernelInterface;
use Twig\Extra\TwigExtraBundle\DependencyInjection\Compiler\MissingExtensionSuggestorPass;
if (!method_exists(ContainerBuilder::class, 'getAutoconfiguredAttributes')) {
if (method_exists(KernelInterface::class, 'getShareDir')) {
class TwigExtraBundle extends Bundle
{
public function build(ContainerBuilder $container): void