mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-28 02:23:51 +00:00
apply rector rules: symfony **UP TO** 44
This commit is contained in:
@@ -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