@@ -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 | } |
@@ -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 | } |
@@ -23,7 +23,7 @@ |
||
| 23 | 23 | use Sylius\Component\Core\Repository\AddressRepositoryInterface; |
| 24 | 24 | |
| 25 | 25 | /** @experimental */ |
| 26 | -final class AddressCollectionDataProvider implements CollectionDataProviderInterface,RestrictedDataProviderInterface |
|
| 26 | +final class AddressCollectionDataProvider implements CollectionDataProviderInterface, RestrictedDataProviderInterface |
|
| 27 | 27 | { |
| 28 | 28 | /** @var AddressRepositoryInterface */ |
| 29 | 29 | private $addressRepository; |
@@ -43,7 +43,7 @@ |
||
| 43 | 43 | Assert::notNull($order = $this->orderRepository->findOneBy(['tokenValue' => $value->getOrderTokenValue()])); |
| 44 | 44 | |
| 45 | 45 | /** @var PaymentInterface $payment */ |
| 46 | - foreach($order->getPayments() as $payment) { |
|
| 46 | + foreach ($order->getPayments() as $payment) { |
|
| 47 | 47 | if (!$payment->getMethod()->isEnabled()) { |
| 48 | 48 | $this->context->addViolation( |
| 49 | 49 | $constraint->message, |
@@ -56,7 +56,7 @@ |
||
| 56 | 56 | |
| 57 | 57 | $builder->get('verifiedAt')->addModelTransformer(new UserVerifiedAtToBooleanTransformer(), true); |
| 58 | 58 | |
| 59 | - $builder->addEventListener(FormEvents::POST_SET_DATA, static function(FormEvent $event) { |
|
| 59 | + $builder->addEventListener(FormEvents::POST_SET_DATA, static function (FormEvent $event) { |
|
| 60 | 60 | /** @var ShopUser|null $data */ |
| 61 | 61 | $data = $event->getData(); |
| 62 | 62 | if (null === $data) { |
@@ -813,7 +813,7 @@ |
||
| 813 | 813 | */ |
| 814 | 814 | public function iShouldSeeThisShippingAddressAsShippingAndBillingAddress(string $fullName, string ...$addressTypes): void |
| 815 | 815 | { |
| 816 | - foreach($addressTypes as $addressType){ |
|
| 816 | + foreach ($addressTypes as $addressType) { |
|
| 817 | 817 | $this->hasFullNameInAddress($fullName, $addressType); |
| 818 | 818 | } |
| 819 | 819 | } |
@@ -507,7 +507,7 @@ |
||
| 507 | 507 | |
| 508 | 508 | $addresses = $this->responseChecker->getCollection($this->addressClient->index()); |
| 509 | 509 | /** @var AddressInterface $address */ |
| 510 | - foreach ($addresses as $address){ |
|
| 510 | + foreach ($addresses as $address) { |
|
| 511 | 511 | if ($firstName === $address['firstName'] && $lastName === $address['lastName']) { |
| 512 | 512 | return $address['@id']; |
| 513 | 513 | } |