Test Failed
Pull Request — master (#12)
by
unknown
06:46
created
src/Method/Payment/Payment.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -426,7 +426,7 @@
 block discarded – undo
426 426
      */
427 427
     public function setThreeDS2AuthorizationInformation(
428 428
         ThreeDS2AuthorizationInformation $threeDS2AuthorizationInformation
429
-    ){
429
+    ) {
430 430
         $this->threeDS2AuthorizationInformation = $threeDS2AuthorizationInformation;
431 431
     }
432 432
 
Please login to merge, or discard this patch.
src/Method/Payment/Create.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -41,11 +41,11 @@  discard block
 block discarded – undo
41 41
     {
42 42
         return new Assert\Collection([
43 43
             'amount' =>  $this->buildElement('float', 1),
44
-            'currency' => $this->buildElement('string', 1, ['min' => 3,'max' => 3]),
44
+            'currency' => $this->buildElement('string', 1, ['min' => 3, 'max' => 3]),
45 45
             'settle' => $this->buildElement('bool'),
46
-            'order_id' => $this->buildElement('string', 0, ['min' => 2,'max' => 50]),
46
+            'order_id' => $this->buildElement('string', 0, ['min' => 2, 'max' => 50]),
47 47
             'description' => $this->buildElement('string', 0, ['max' => 255]),
48
-            'country' => $this->buildElement('string', 1, ['min' => 2,'max' => 2]),
48
+            'country' => $this->buildElement('string', 1, ['min' => 2, 'max' => 2]),
49 49
             'payment_method' => new Assert\Required([
50 50
                 new Assert\Type(['type' => 'string']),
51 51
                 new Assert\Choice([
@@ -73,7 +73,7 @@  discard block
 block discarded – undo
73 73
                     ]),
74 74
                     'exp_year' => $this->buildElement(
75 75
                         'integer', 1, 
76
-                        ['min' => 4,'max' => 4],
76
+                        ['min' => 4, 'max' => 4],
77 77
                         new Assert\Range(['min' => date('Y')]),
78 78
                     ),
79 79
                     'exp_month' => $this->buildElement('integer', 1),
@@ -147,7 +147,7 @@  discard block
 block discarded – undo
147 147
         ]); 
148 148
     }
149 149
 
150
-    private function buildElement($typeValue, $isRequired=0, $length=0, $args=0)
150
+    private function buildElement($typeValue, $isRequired = 0, $length = 0, $args = 0)
151 151
     {
152 152
         $inside_array = [
153 153
             new Assert\Type(['type', $typeValue]),
Please login to merge, or discard this patch.
Braces   +9 added lines, -3 removed lines patch added patch discarded remove patch
@@ -152,9 +152,15 @@
 block discarded – undo
152 152
         $inside_array = [
153 153
             new Assert\Type(['type', $typeValue]),
154 154
         ];
155
-        if ($isRequired) array_unshift($inside_array, new Assert\NotBlank());
156
-        if ($length) array_push($inside_array, new Assert\Length($length));
157
-        if ($args) array_push($inside_array, $args);
155
+        if ($isRequired) {
156
+            array_unshift($inside_array, new Assert\NotBlank());
157
+        }
158
+        if ($length) {
159
+            array_push($inside_array, new Assert\Length($length));
160
+        }
161
+        if ($args) {
162
+            array_push($inside_array, $args);
163
+        }
158 164
         
159 165
         return $isRequired 
160 166
             ? new Assert\Required($inside_array)
Please login to merge, or discard this patch.