mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-29 10:05:03 +00:00
apply more cs rules for php-cs
This commit is contained in:
@@ -13,9 +13,7 @@ namespace Chill\Migrations\Person;
|
||||
|
||||
use Doctrine\DBAL\Schema\Schema;
|
||||
use Doctrine\Migrations\AbstractMigration;
|
||||
use Exception;
|
||||
use libphonenumber\PhoneNumberUtil;
|
||||
use RuntimeException;
|
||||
use Symfony\Component\DependencyInjection\ContainerAwareInterface;
|
||||
use Symfony\Component\DependencyInjection\ContainerAwareTrait;
|
||||
|
||||
@@ -25,7 +23,7 @@ final class Version20220215135509 extends AbstractMigration implements Container
|
||||
|
||||
public function down(Schema $schema): void
|
||||
{
|
||||
throw new Exception('You should not do that.');
|
||||
throw new \Exception('You should not do that.');
|
||||
}
|
||||
|
||||
public function getDescription(): string
|
||||
@@ -39,7 +37,7 @@ final class Version20220215135509 extends AbstractMigration implements Container
|
||||
->getParameter('chill_main')['phone_helper']['default_carrier_code'];
|
||||
|
||||
if (null === $carrier_code) {
|
||||
throw new RuntimeException('no carrier code');
|
||||
throw new \RuntimeException('no carrier code');
|
||||
}
|
||||
|
||||
$this->addSql('ALTER TABLE chill_person_person ALTER phonenumber TYPE TEXT');
|
||||
@@ -53,9 +51,9 @@ final class Version20220215135509 extends AbstractMigration implements Container
|
||||
$this->addSql('COMMENT ON COLUMN chill_person_person.mobilenumber IS NULL');
|
||||
|
||||
$this->addSql(
|
||||
'UPDATE chill_person_person SET ' .
|
||||
$this->buildMigrationPhonenumberClause($carrier_code, 'phonenumber') .
|
||||
', ' .
|
||||
'UPDATE chill_person_person SET '.
|
||||
$this->buildMigrationPhonenumberClause($carrier_code, 'phonenumber').
|
||||
', '.
|
||||
$this->buildMigrationPhoneNumberClause($carrier_code, 'mobilenumber')
|
||||
);
|
||||
|
||||
@@ -65,7 +63,7 @@ final class Version20220215135509 extends AbstractMigration implements Container
|
||||
$this->addSql('COMMENT ON COLUMN chill_person_phone.phonenumber IS NULL');
|
||||
|
||||
$this->addSql(
|
||||
'UPDATE chill_person_phone SET ' .
|
||||
'UPDATE chill_person_phone SET '.
|
||||
$this->buildMigrationPhoneNumberClause($carrier_code, 'phonenumber')
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user