Completed
Pull Request — master (#54)
by Rafał
08:56 queued 05:17
created
src/PH/Bundle/CoreBundle/Doctrine/ORM/PaymentMethodRepository.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@
 block discarded – undo
33 33
      */
34 34
     protected function applyCriteria(QueryBuilder $queryBuilder, array $criteria = []): void
35 35
     {
36
-        $criteria = array_filter($criteria, function ($value) {
36
+        $criteria = array_filter($criteria, function($value) {
37 37
             return !is_null($value);
38 38
         });
39 39
 
Please login to merge, or discard this patch.
src/PH/Bundle/CoreBundle/Form/Extension/PaymentMethodTypeExtension.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -29,7 +29,7 @@
 block discarded – undo
29 29
                 'data' => $gatewayFactory,
30 30
             ])
31 31
             ->add('supportsRecurring', CheckboxType::class)
32
-            ->addEventListener(FormEvents::SUBMIT, function (FormEvent $event) {
32
+            ->addEventListener(FormEvents::SUBMIT, function(FormEvent $event) {
33 33
                 $paymentMethod = $event->getData();
34 34
 
35 35
                 if (!$paymentMethod instanceof PaymentMethodInterface) {
Please login to merge, or discard this patch.
src/PH/Component/Core/Model/Subscription.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@
 block discarded – undo
114 114
             return null;
115 115
         }
116 116
 
117
-        $payment = $this->payments->filter(function (PaymentInterface $payment) use ($state) {
117
+        $payment = $this->payments->filter(function(PaymentInterface $payment) use ($state) {
118 118
             return null === $state || $payment->getState() === $state;
119 119
         })->last();
120 120
 
Please login to merge, or discard this patch.
src/PH/Component/Core/Resolver/SubscriptionPaymentStateResolver.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -103,7 +103,7 @@
 block discarded – undo
103 103
      */
104 104
     private function getPaymentsWithState(SubscriptionInterface $subscription, string $state)
105 105
     {
106
-        return $subscription->getPayments()->filter(function (PaymentInterface $payment) use ($state) {
106
+        return $subscription->getPayments()->filter(function(PaymentInterface $payment) use ($state) {
107 107
             return $state === $payment->getState();
108 108
         });
109 109
     }
Please login to merge, or discard this patch.
src/PH/Bundle/CoreBundle/Form/Extension/SubscriptionTypeExtension.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
      */
37 37
     public function buildForm(FormBuilderInterface $builder, array $options)
38 38
     {
39
-        $formModifier = function (FormInterface $form, string $type = null) {
39
+        $formModifier = function(FormInterface $form, string $type = null) {
40 40
             $methods = null === $type ? [] : $this->paymentMethodsProvider->getSupportedMethods($type);
41 41
 
42 42
             $form->add('method', PaymentMethodChoiceType::class, [
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
 
48 48
         $builder->addEventListener(
49 49
             FormEvents::PRE_SET_DATA,
50
-            function (FormEvent $event) use ($formModifier) {
50
+            function(FormEvent $event) use ($formModifier) {
51 51
                 $data = $event->getData();
52 52
 
53 53
                 $formModifier($event->getForm(), $data->getType());
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 
57 57
         $builder->get('type')->addEventListener(
58 58
             FormEvents::POST_SUBMIT,
59
-            function (FormEvent $event) use ($formModifier) {
59
+            function(FormEvent $event) use ($formModifier) {
60 60
                 $type = $event->getForm()->getData();
61 61
                 $formModifier($event->getForm()->getParent(), $type);
62 62
             }
Please login to merge, or discard this patch.
src/PH/Bundle/SubscriptionBundle/Form/Type/SubscriptionType.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -39,10 +39,10 @@  discard block
 block discarded – undo
39 39
 
40 40
         $builder->get('startDate')
41 41
             ->addModelTransformer(new CallbackTransformer(
42
-                function ($value) {
42
+                function($value) {
43 43
                     return $value;
44 44
                 },
45
-                function ($value) {
45
+                function($value) {
46 46
                     if (is_string($value)) {
47 47
                         return new \DateTime($value);
48 48
                     }
@@ -54,10 +54,10 @@  discard block
 block discarded – undo
54 54
             ->add('metadata', TextType::class);
55 55
 
56 56
         $builder->get('metadata')->addModelTransformer(new CallbackTransformer(
57
-            function ($value) {
57
+            function($value) {
58 58
                 return $value;
59 59
             },
60
-            function ($value) {
60
+            function($value) {
61 61
                 $collection = new ArrayCollection();
62 62
 
63 63
                 foreach ((array) $value as $key => $item) {
Please login to merge, or discard this patch.