@@ -102,7 +102,7 @@ |
||
102 | 102 | |
103 | 103 | public static function findBy(RepositoryInterface $repository, string $field, array $criteria = []): \Closure |
104 | 104 | { |
105 | - return function (Options $options, ?array $previousValues) use ($repository, $field, $criteria): ?iterable { |
|
105 | + return function (Options $options, ?array $previousValues) use ($repository, $field, $criteria) : ?iterable { |
|
106 | 106 | if (null === $previousValues || [] === $previousValues) { |
107 | 107 | return $previousValues; |
108 | 108 | } |
@@ -65,10 +65,10 @@ |
||
65 | 65 | { |
66 | 66 | $this->client->updateRequestData([ |
67 | 67 | 'translations' => [ |
68 | - $localeCode => [ |
|
69 | - 'name' => $productAssociationTypeName, |
|
70 | - 'locale' => $localeCode, |
|
71 | - ], |
|
68 | + $localeCode => [ |
|
69 | + 'name' => $productAssociationTypeName, |
|
70 | + 'locale' => $localeCode, |
|
71 | + ], |
|
72 | 72 | ], |
73 | 73 | ]); |
74 | 74 | } |
@@ -48,7 +48,8 @@ |
||
48 | 48 | |
49 | 49 | function it_throws_an_exception_if_constraint_is_not_of_expected_type(): void |
50 | 50 | { |
51 | - $this->shouldThrow(\InvalidArgumentException::class)->during('validate', ['', new class() extends Constraint { |
|
51 | + $this->shouldThrow(\InvalidArgumentException::class)->during('validate', ['', new class() extends Constraint |
|
52 | + { |
|
52 | 53 | }]); |
53 | 54 | } |
54 | 55 |
@@ -166,7 +166,7 @@ |
||
166 | 166 | |
167 | 167 | private static function getCouponNormalizer(?FactoryInterface $couponFactory): \Closure |
168 | 168 | { |
169 | - return function (Options $options, array $couponDefinitions) use ($couponFactory): array { |
|
169 | + return function (Options $options, array $couponDefinitions) use ($couponFactory) : array { |
|
170 | 170 | if (null === $couponFactory) { |
171 | 171 | throw new \RuntimeException('You must configure a $couponFactory'); |
172 | 172 | } |
@@ -46,7 +46,8 @@ |
||
46 | 46 | { |
47 | 47 | $this |
48 | 48 | ->shouldThrow(\InvalidArgumentException::class) |
49 | - ->during('validate', ['', new class() extends Constraint { |
|
49 | + ->during('validate', ['', new class() extends Constraint |
|
50 | + { |
|
50 | 51 | }]) |
51 | 52 | ; |
52 | 53 | } |
@@ -105,11 +105,11 @@ |
||
105 | 105 | if (isset($sorting['price'])) { |
106 | 106 | // Another hack, the subquery to get the first position variant |
107 | 107 | $subQuery = $this->createQueryBuilder('m') |
108 | - ->select('min(v.position)') |
|
109 | - ->innerJoin('m.variants', 'v') |
|
110 | - ->andWhere('m.id = :product_id') |
|
111 | - ->andWhere('v.enabled = :enabled') |
|
112 | - ; |
|
108 | + ->select('min(v.position)') |
|
109 | + ->innerJoin('m.variants', 'v') |
|
110 | + ->andWhere('m.id = :product_id') |
|
111 | + ->andWhere('v.enabled = :enabled') |
|
112 | + ; |
|
113 | 113 | |
114 | 114 | $queryBuilder |
115 | 115 | ->addSelect('variant') |
@@ -40,7 +40,8 @@ discard block |
||
40 | 40 | { |
41 | 41 | $this |
42 | 42 | ->shouldThrow(\InvalidArgumentException::class) |
43 | - ->during('validate', [new CompleteOrder(), new class() extends Constraint { |
|
43 | + ->during('validate', [new CompleteOrder(), new class() extends Constraint |
|
44 | + { |
|
44 | 45 | }]) |
45 | 46 | ; |
46 | 47 | } |
@@ -49,7 +50,8 @@ discard block |
||
49 | 50 | { |
50 | 51 | $this |
51 | 52 | ->shouldThrow(\InvalidArgumentException::class) |
52 | - ->during('validate', ['', new class() extends Constraint { |
|
53 | + ->during('validate', ['', new class() extends Constraint |
|
54 | + { |
|
53 | 55 | }]) |
54 | 56 | ; |
55 | 57 | } |
@@ -48,7 +48,8 @@ |
||
48 | 48 | |
49 | 49 | function it_throws_an_exception_if_constraint_is_not_of_expected_type(): void |
50 | 50 | { |
51 | - $this->shouldThrow(\InvalidArgumentException::class)->during('validate', ['', new class() extends Constraint { |
|
51 | + $this->shouldThrow(\InvalidArgumentException::class)->during('validate', ['', new class() extends Constraint |
|
52 | + { |
|
52 | 53 | }]); |
53 | 54 | } |
54 | 55 |
@@ -72,7 +72,7 @@ |
||
72 | 72 | ]; |
73 | 73 | |
74 | 74 | if ($zone->getType() === ZoneInterface::TYPE_ZONE) { |
75 | - $entryOptions['entry_options']['choice_filter'] = static function (?ZoneInterface $subZone) use ($zone): bool { |
|
75 | + $entryOptions['entry_options']['choice_filter'] = static function (?ZoneInterface $subZone) use ($zone) : bool { |
|
76 | 76 | return $subZone !== null && $zone->getId() !== $subZone->getId(); |
77 | 77 | }; |
78 | 78 | } |