Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions extra/twig-extra-bundle/TwigExtraBundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,14 @@
use Symfony\Component\HttpKernel\Bundle\Bundle;
use Twig\Extra\TwigExtraBundle\DependencyInjection\Compiler\MissingExtensionSuggestorPass;

if (!method_exists(ContainerBuilder::class, 'getAutoconfiguredAttributes')) {
$refMethod = new \ReflectionMethod(\Symfony\Component\HttpKernel\Bundle\Bundle::class, 'build');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should be removed as this is unused.


if ($refMethod->hasReturnType()) {
class TwigExtraBundle extends Bundle
{
public function build(ContainerBuilder $container): void
{
parent::build($container);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be reverted

$container->addCompilerPass(new MissingExtensionSuggestorPass());
}
}
Expand All @@ -32,8 +33,8 @@ class TwigExtraBundle extends Bundle
public function build(ContainerBuilder $container)
{
parent::build($container);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be reverted

$container->addCompilerPass(new MissingExtensionSuggestorPass());
}
}
}

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be reverted