Run Rector on your code to see what it can do for you:
{ public function run(bool $param) { - $constraints = new Assert\Collection([ - 'distributorCode' => [new Assert\NotBlank(), new Assert\Type('string')], - 'warehouseId' => [new Assert\Type('string')], - 'customerCode' => [new Assert\NotBlank(), new Assert\Type('string')], - 'clientAddressId' => [new Assert\NotBlank(), new Assert\Type('string')], - ]); + $constraints = new Assert\Collection(distributorCode: [new Assert\NotBlank(), new Assert\Type('string')], warehouseId: [new Assert\Type('string')], customerCode: [new Assert\NotBlank(), new Assert\Type('string')], clientAddressId: [new Assert\NotBlank(), new Assert\Type('string')]); } }
Applied Rules:
Not a change you expect?
rector.php