Passed
Push — master ( 047831...1469ea )
by mahdi
03:01
created
src/Drivers/Pasargad/Utils/RSA.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
             $block_type = "\x01";
92 92
             $padding = str_repeat("\xFF", $pad_length);
93 93
         }
94
-        return "\x00" . $block_type . $padding . "\x00" . $data;
94
+        return "\x00".$block_type.$padding."\x00".$data;
95 95
     }
96 96
 
97 97
     public static function removePKCS1Padding($data, $blocksize)
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
         while ($div > 0) {
137 137
             $mod = bcmod($div, $base);
138 138
             $div = bcdiv($div, $base);
139
-            $result = chr($mod) . $result;
139
+            $result = chr($mod).$result;
140 140
         }
141 141
         return str_pad($result, $blocksize, "\x00", STR_PAD_LEFT);
142 142
     }
Please login to merge, or discard this patch.
src/Drivers/Pasargad/Pasargad.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -193,7 +193,7 @@
 block discarded – undo
193 193
         $terminalCode = $this->settings->terminalCode;
194 194
         $amount = $this->invoice->getAmount(); //rial
195 195
         $redirectAddress = $this->settings->callbackUrl;
196
-        $invoiceNumber = crc32($this->invoice->getUuid()) . rand(0, time());
196
+        $invoiceNumber = crc32($this->invoice->getUuid()).rand(0, time());
197 197
         $timeStamp = date("Y/m/d H:i:s");
198 198
         $invoiceDate = date("Y/m/d H:i:s");
199 199
 
Please login to merge, or discard this patch.
src/EventEmitter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
             return;
71 71
         }
72 72
 
73
-        array_walk($listeners[$event], function ($listener) use ($arguments) {
73
+        array_walk($listeners[$event], function($listener) use ($arguments) {
74 74
             call_user_func_array($listener, $arguments);
75 75
         });
76 76
     }
Please login to merge, or discard this patch.
src/RedirectionForm.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -104,7 +104,7 @@
 block discarded – undo
104 104
      */
105 105
     protected function getDefaultViewRenderer() : callable
106 106
     {
107
-        return function (string $view, string $action, array $inputs, string $method) {
107
+        return function(string $view, string $action, array $inputs, string $method) {
108 108
             ob_start();
109 109
 
110 110
             require($view);
Please login to merge, or discard this patch.
src/Drivers/Parsian/Parsian.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
      */
81 81
     public function pay() : RedirectionForm
82 82
     {
83
-        $payUrl = $this->settings->apiPaymentUrl . '?Token=' . $this->invoice->getTransactionId() ;
83
+        $payUrl = $this->settings->apiPaymentUrl.'?Token='.$this->invoice->getTransactionId();
84 84
 
85 85
         return $this->redirectWithForm(
86 86
             $payUrl,
Please login to merge, or discard this patch.
src/Drivers/Sepehr/Sepehr.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
     public function __construct(Invoice $invoice, $settings)
40 40
     {
41 41
         $this->invoice($invoice);
42
-        $this->settings = (object)$settings;
42
+        $this->settings = (object) $settings;
43 43
     }
44 44
 
45 45
     /**
@@ -56,10 +56,10 @@  discard block
 block discarded – undo
56 56
         $mobile = '';
57 57
         //set CellNumber for get user cards
58 58
         if (!empty($this->invoice->getDetails()['mobile'])) {
59
-            $mobile = '&CellNumber=' . $this->invoice->getDetails()['mobile'];
59
+            $mobile = '&CellNumber='.$this->invoice->getDetails()['mobile'];
60 60
         }
61 61
 
62
-        $data_query = 'Amount=' . $this->test_input($amount) . '&callbackURL=' . $this->test_input($this->settings->callbackUrl) . '&InvoiceID=' . $this->test_input($this->invoice->getUuid()) . '&TerminalID=' . $this->test_input($this->settings->terminalId) . '&Payload=' . $this->test_input("") . $mobile;
62
+        $data_query = 'Amount='.$this->test_input($amount).'&callbackURL='.$this->test_input($this->settings->callbackUrl).'&InvoiceID='.$this->test_input($this->invoice->getUuid()).'&TerminalID='.$this->test_input($this->settings->terminalId).'&Payload='.$this->test_input("").$mobile;
63 63
         $address_service_token = $this->settings->apiGetToken;
64 64
 
65 65
         $token_array = $this->makeHttpChargeRequest('POST', $data_query, $address_service_token);
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
             $this->notVerified($resp_code);
113 113
         }
114 114
 
115
-        $data_query = 'digitalreceipt=' . Request::input('digitalreceipt') . '&Tid=' . $this->settings->terminalId;
115
+        $data_query = 'digitalreceipt='.Request::input('digitalreceipt').'&Tid='.$this->settings->terminalId;
116 116
         $advice_array = $this->makeHttpChargeRequest('POST', $data_query, $this->settings->apiVerificationUrl);
117 117
         $decode_advice_array = json_decode($advice_array);
118 118
 
Please login to merge, or discard this patch.
src/Drivers/Saman/Saman.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -37,7 +37,7 @@  discard block
 block discarded – undo
37 37
     public function __construct(Invoice $invoice, $settings)
38 38
     {
39 39
         $this->invoice($invoice);
40
-        $this->settings = (object)$settings;
40
+        $this->settings = (object) $settings;
41 41
     }
42 42
 
43 43
     /**
@@ -68,7 +68,7 @@  discard block
 block discarded – undo
68 68
 
69 69
         $response = $soap->RequestToken($data['MID'], $data['ResNum'], $data['Amount'], $data['CellNumber']);
70 70
 
71
-        $status = (int)$response;
71
+        $status = (int) $response;
72 72
 
73 73
         if ($status < 0) { // if something has done in a wrong way
74 74
             $this->purchaseFailed($response);
@@ -116,13 +116,13 @@  discard block
 block discarded – undo
116 116
         );
117 117
 
118 118
         $soap = new \SoapClient($this->settings->apiVerificationUrl);
119
-        $status = (int)$soap->VerifyTransaction($data['RefNum'], $data['merchantId']);
119
+        $status = (int) $soap->VerifyTransaction($data['RefNum'], $data['merchantId']);
120 120
 
121 121
         if ($status < 0) {
122 122
             $this->notVerified($status);
123 123
         }
124 124
 
125
-        $receipt =  $this->createReceipt($data['RefNum']);
125
+        $receipt = $this->createReceipt($data['RefNum']);
126 126
         $receipt->detail([
127 127
             'traceNo' => Request::input('TraceNo'),
128 128
             'referenceNo' => Request::input('RRN'),
Please login to merge, or discard this patch.
src/Drivers/Payir/Payir.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -111,7 +111,7 @@
 block discarded – undo
111 111
      */
112 112
     public function pay(): RedirectionForm
113 113
     {
114
-        $payUrl = $this->settings->apiPaymentUrl . $this->invoice->getTransactionId();
114
+        $payUrl = $this->settings->apiPaymentUrl.$this->invoice->getTransactionId();
115 115
 
116 116
         return $this->redirectWithForm($payUrl, [], 'GET');
117 117
     }
Please login to merge, or discard this patch.
src/Drivers/Local/Local.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -156,7 +156,7 @@
 block discarded – undo
156 156
     {
157 157
         $urlWithQuery = $url;
158 158
         foreach ($params as $key => $value) {
159
-            $urlWithQuery .= (parse_url($urlWithQuery, PHP_URL_QUERY) ? '&' : '?') . "{$key}={$value}";
159
+            $urlWithQuery .= (parse_url($urlWithQuery, PHP_URL_QUERY) ? '&' : '?')."{$key}={$value}";
160 160
         }
161 161
         return $urlWithQuery;
162 162
     }
Please login to merge, or discard this patch.