mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-10-22 05:02:50 +00:00
rector fixes
This commit is contained in:
@@ -45,7 +45,7 @@ class PhonenumberNormalizer implements ContextAwareNormalizerInterface, Denormal
|
||||
|
||||
try {
|
||||
return $this->phoneNumberUtil->parse($data, $this->defaultCarrierCode);
|
||||
} catch (NumberParseException $e) {
|
||||
} catch (NumberParseException) {
|
||||
$phonenumber = new PhoneNumber();
|
||||
$phonenumber->setRawInput($data);
|
||||
|
||||
|
@@ -86,7 +86,7 @@ final class PersonJsonDenormalizer implements DenormalizerInterface, Denormalize
|
||||
foreach ($data['altNames'] as $altNameData) {
|
||||
if (!array_key_exists('key', $altNameData)
|
||||
|| !array_key_exists('value', $altNameData)
|
||||
|| '' === trim($altNameData['key'])
|
||||
|| '' === trim((string) $altNameData['key'])
|
||||
) {
|
||||
throw new UnexpectedValueException('format for alt name is not correct');
|
||||
}
|
||||
|
@@ -79,7 +79,7 @@ class PersonIdentifierListApiControllerTest extends TestCase
|
||||
return '';
|
||||
}
|
||||
|
||||
public function validate(ExecutionContextInterface $context, PersonIdentifier $identifier, PersonIdentifierDefinition $definition): void {}
|
||||
public function validate(ExecutionContextInterface $context, PersonIdentifier $identifier, PersonIdentifierDefinition $definition = null): void {}
|
||||
|
||||
public function getDefaultValue(PersonIdentifierDefinition $definition): array
|
||||
{
|
||||
|
@@ -63,7 +63,7 @@ final class ValidIdentifierConstraintValidatorTest extends ConstraintValidatorTe
|
||||
|
||||
// engine that returns one violation
|
||||
$engine = new class ([$violation]) implements PersonIdentifierEngineInterface {
|
||||
public function __construct(private array $violations) {}
|
||||
public function __construct(private readonly array $violations) {}
|
||||
|
||||
public static function getName(): string
|
||||
{
|
||||
|
Reference in New Issue
Block a user