welcome back to dyb-tech
This commit is contained in:
Vendored
+20
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Bundle\DoctrineBundle\DependencyInjection\Compiler;
|
||||
|
||||
use Doctrine\Bundle\DoctrineBundle\Controller\ProfilerController;
|
||||
use Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface;
|
||||
use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
|
||||
/** @internal */
|
||||
final class RemoveProfilerControllerPass implements CompilerPassInterface
|
||||
{
|
||||
public function process(ContainerBuilder $container): void
|
||||
{
|
||||
if ($container->has('twig') && $container->has('profiler')) {
|
||||
return;
|
||||
}
|
||||
|
||||
$container->removeDefinition(ProfilerController::class);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user