Completed
Pull Request — master (#15)
by angel
01:46
created
Instapago/InstapagoGateway/InstapagoPayment.php 1 patch
Spacing   +8 added lines, -13 removed lines patch added patch discarded remove patch
@@ -101,7 +101,7 @@  discard block
 block discarded – undo
101 101
             $this->statusId = $statusId;
102 102
             $this->ipAddres = $ipAddres;
103 103
 
104
-            $url = $this->root.'payment'; // endpoint
104
+            $url = $this->root . 'payment'; // endpoint
105 105
 
106 106
             $fields = [
107 107
                 'KeyID'             => $this->keyId, //required
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
             $this->idPago = $idPago;
146 146
             $this->amount = $amount;
147 147
 
148
-            $url = $this->root.'complete'; // endpoint
148
+            $url = $this->root . 'complete'; // endpoint
149 149
 
150 150
             $fields = [
151 151
                 'KeyID'             => $this->keyId, //required
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
 
180 180
             $this->idPago = $idPago;
181 181
 
182
-            $url = $this->root.'payment'; // endpoint
182
+            $url = $this->root . 'payment'; // endpoint
183 183
 
184 184
             $fields = [
185 185
                 'KeyID'             => $this->keyId, //required
@@ -190,7 +190,7 @@  discard block
 block discarded – undo
190 190
             $myCurl = curl_init();
191 191
             curl_setopt($myCurl, CURLOPT_RETURNTRANSFER, 1);
192 192
             curl_setopt($myCurl, CURLOPT_CUSTOMREQUEST, "DELETE");
193
-            curl_setopt($myCurl, CURLOPT_URL, $url.'?'.'KeyID='.$this->keyId.'&PublicKeyId='.$this->publicKeyId.'&id='.$this->idPago);
193
+            curl_setopt($myCurl, CURLOPT_URL, $url . '?' . 'KeyID=' . $this->keyId . '&PublicKeyId=' . $this->publicKeyId . '&id=' . $this->idPago);
194 194
             $server_output = curl_exec($myCurl);
195 195
             curl_close($myCurl);
196 196
             $obj = json_decode($server_output);
@@ -218,10 +218,10 @@  discard block
 block discarded – undo
218 218
 
219 219
             $this->idPago = $idPago;
220 220
 
221
-            $url = $this->root.'payment'; // endpoint
221
+            $url = $this->root . 'payment'; // endpoint
222 222
 
223 223
             $myCurl = curl_init();
224
-            curl_setopt($myCurl, CURLOPT_URL, $url.'?'.'KeyID='.$this->keyId.'&PublicKeyId='.$this->publicKeyId.'&id='.$this->idPago);
224
+            curl_setopt($myCurl, CURLOPT_URL, $url . '?' . 'KeyID=' . $this->keyId . '&PublicKeyId=' . $this->publicKeyId . '&id=' . $this->idPago);
225 225
             curl_setopt($myCurl, CURLOPT_RETURNTRANSFER, 1);
226 226
             $server_output = curl_exec($myCurl);
227 227
             curl_close($myCurl);
@@ -256,7 +256,7 @@  discard block
 block discarded – undo
256 256
         $server_output = curl_exec($myCurl);
257 257
         curl_close($myCurl);
258 258
         $obj = json_decode($server_output);
259
-<<<<<<< HEAD
259
+<< << <<< HEAD
260 260
 
261 261
         return $obj;
262 262
 =======
@@ -312,9 +312,4 @@  discard block
 block discarded – undo
312 312
     private function checkRequiredParams(array $params)
313 313
     {
314 314
         foreach ($params as $param) {
315
-            if (empty($param)) {
316
-                throw new InstapagoException('Parámetros faltantes para procesar el pago. Verifique la documentación.');
317
-            }
318
-        }
319
-    }
320
-} // end class
315
+            if (empty($param
321 316
\ No newline at end of file
Please login to merge, or discard this patch.