mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-20 14:43:49 +00:00
apply rector rules: symfony **UP TO** 44
This commit is contained in:
@@ -22,6 +22,6 @@ class ChillThirdPartyBundle extends Bundle
|
||||
parent::build($container);
|
||||
$container->registerForAutoconfiguration(ThirdPartyTypeProviderInterface::class)
|
||||
->addTag('chill_3party.provider');
|
||||
$container->addCompilerPass(new ThirdPartyTypeCompilerPass());
|
||||
$container->addCompilerPass(new ThirdPartyTypeCompilerPass(), \Symfony\Component\DependencyInjection\Compiler\PassConfig::TYPE_BEFORE_OPTIMIZATION, 0);
|
||||
}
|
||||
}
|
||||
|
@@ -21,6 +21,10 @@ use Symfony\Component\DependencyInjection\ContainerInterface;
|
||||
final class Version20230215175150 extends AbstractMigration implements ContainerAwareInterface
|
||||
{
|
||||
public ContainerInterface $container;
|
||||
public function __construct(\Doctrine\DBAL\Connection $connection, \Psr\Log\LoggerInterface $logger, private \Doctrine\ORM\EntityManager $entityManager)
|
||||
{
|
||||
parent::__construct($connection, $logger);
|
||||
}
|
||||
|
||||
public function down(Schema $schema): void
|
||||
{
|
||||
@@ -45,7 +49,7 @@ final class Version20230215175150 extends AbstractMigration implements Container
|
||||
{
|
||||
$this->addSql('ALTER TABLE chill_3party.third_party ADD profession TEXT DEFAULT \'\' NOT NULL');
|
||||
|
||||
$em = $this->container->get('doctrine.orm.entity_manager');
|
||||
$em = $this->entityManager;
|
||||
$professions = $em->getRepository(ThirdPartyProfession::class)->findAll();
|
||||
|
||||
foreach ($professions as $p) {
|
||||
|
Reference in New Issue
Block a user