Completed
Push — master ( a4cd9f...0f09a1 )
by Adriano
03:11
created
src/Integracao/ControlPay/Model/PagamentoExterno.php 1 patch
Braces   +12 added lines, -8 removed lines patch added patch discarded remove patch
@@ -144,9 +144,10 @@  discard block
 block discarded – undo
144 144
     {
145 145
         $this->pagamentoExternoStatus = $pagamentoExternoStatus;
146 146
 
147
-        if(is_array($this->pagamentoExternoStatus))
148
-            $this->pagamentoExternoStatus = SerializerHelper::denormalize(
147
+        if(is_array($this->pagamentoExternoStatus)) {
148
+                    $this->pagamentoExternoStatus = SerializerHelper::denormalize(
149 149
                 $this->pagamentoExternoStatus, PagamentoExternoStatus::class);
150
+        }
150 151
 
151 152
         return $this;
152 153
     }
@@ -167,8 +168,9 @@  discard block
 block discarded – undo
167 168
     {
168 169
         $this->pessoa = $pessoa;
169 170
 
170
-        if(is_array($this->pessoa))
171
-            $this->pessoa = SerializerHelper::denormalize($this->pessoa, Pessoa::class);
171
+        if(is_array($this->pessoa)) {
172
+                    $this->pessoa = SerializerHelper::denormalize($this->pessoa, Pessoa::class);
173
+        }
172 174
 
173 175
         return $this;
174 176
     }
@@ -189,8 +191,9 @@  discard block
 block discarded – undo
189 191
     {
190 192
         $this->intencoesVenda = $intencoesVenda;
191 193
 
192
-        if(is_array($this->intencoesVenda))
193
-            $this->intencoesVenda = SerializerHelper::denormalize($this->intencoesVenda, IntencaoVenda::class);
194
+        if(is_array($this->intencoesVenda)) {
195
+                    $this->intencoesVenda = SerializerHelper::denormalize($this->intencoesVenda, IntencaoVenda::class);
196
+        }
194 197
 
195 198
         return $this;
196 199
     }
@@ -211,8 +214,9 @@  discard block
 block discarded – undo
211 214
     {
212 215
         $this->terminal = $terminal;
213 216
 
214
-        if(is_array($this->terminal))
215
-            $this->terminal = SerializerHelper::denormalize($this->terminal, Terminal::class);
217
+        if(is_array($this->terminal)) {
218
+                    $this->terminal = SerializerHelper::denormalize($this->terminal, Terminal::class);
219
+        }
216 220
 
217 221
         return $this;
218 222
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/FormaPagamento.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -112,8 +112,9 @@
 block discarded – undo
112 112
     {
113 113
         $this->fluxoPagamento = $fluxoPagamento;
114 114
 
115
-        if(is_array($this->fluxoPagamento))
116
-            $this->fluxoPagamento = SerializerHelper::denormalize($this->fluxoPagamento, FluxoPagamento::class);
115
+        if(is_array($this->fluxoPagamento)) {
116
+                    $this->fluxoPagamento = SerializerHelper::denormalize($this->fluxoPagamento, FluxoPagamento::class);
117
+        }
117 118
 
118 119
         return $this;
119 120
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/Produto.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -221,8 +221,9 @@
 block discarded – undo
221 221
     {
222 222
         $this->produtoStatus = $produtoStatus;
223 223
 
224
-        if(is_array($this->produtoStatus))
225
-            $this->produtoStatus = SerializerHelper::denormalize($this->produtoStatus, ProdutoStatus::class);
224
+        if(is_array($this->produtoStatus)) {
225
+                    $this->produtoStatus = SerializerHelper::denormalize($this->produtoStatus, ProdutoStatus::class);
226
+        }
226 227
 
227 228
         return $this;
228 229
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/Pagamento.php 1 patch
Braces   +9 added lines, -6 removed lines patch added patch discarded remove patch
@@ -86,8 +86,9 @@  discard block
 block discarded – undo
86 86
     {
87 87
         $this->contaBancaria = $contaBancaria;
88 88
 
89
-        if(is_array($this->contaBancaria))
90
-            $this->contaBancaria = SerializerHelper::denormalize($this->contaBancaria, ContaBancaria::class);
89
+        if(is_array($this->contaBancaria)) {
90
+                    $this->contaBancaria = SerializerHelper::denormalize($this->contaBancaria, ContaBancaria::class);
91
+        }
91 92
 
92 93
         return $this;
93 94
     }
@@ -108,8 +109,9 @@  discard block
 block discarded – undo
108 109
     {
109 110
         $this->pagamentoStatus = $pagamentoStatus;
110 111
 
111
-        if(is_array($this->pagamentoStatus))
112
-            $this->pagamentoStatus = SerializerHelper::denormalize($this->pagamentoStatus, PagamentoStatus::class);
112
+        if(is_array($this->pagamentoStatus)) {
113
+                    $this->pagamentoStatus = SerializerHelper::denormalize($this->pagamentoStatus, PagamentoStatus::class);
114
+        }
113 115
 
114 116
         return $this;
115 117
     }
@@ -164,10 +166,11 @@  discard block
 block discarded – undo
164 166
      */
165 167
     public function setContaRecebimentoLancamentos($contaRecebimentoLancamentos)
166 168
     {
167
-        if(is_array($contaRecebimentoLancamentos))
168
-            foreach ($contaRecebimentoLancamentos as $contaRecebimentoLancamento) {
169
+        if(is_array($contaRecebimentoLancamentos)) {
170
+                    foreach ($contaRecebimentoLancamentos as $contaRecebimentoLancamento) {
169 171
                 $this->contaRecebimentoLancamentos[] = SerializerHelper::denormalize(
170 172
                     $contaRecebimentoLancamento, ContaRecebimentoLancamento::class);
173
+        }
171 174
             }
172 175
 
173 176
         return $this;
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/ContaRecebimento.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -75,8 +75,9 @@
 block discarded – undo
75 75
     {
76 76
         $this->pessoa = $pessoa;
77 77
 
78
-        if(is_array($this->pessoa))
79
-            $this->pessoa = SerializerHelper::denormalize($pessoa, Pessoa::class);
78
+        if(is_array($this->pessoa)) {
79
+                    $this->pessoa = SerializerHelper::denormalize($pessoa, Pessoa::class);
80
+        }
80 81
 
81 82
         return $this;
82 83
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/Pessoa.php 1 patch
Braces   +3 added lines, -2 removed lines patch added patch discarded remove patch
@@ -252,8 +252,9 @@
 block discarded – undo
252 252
     {
253 253
         $this->pessoaStatus = $pessoaStatus;
254 254
 
255
-        if(is_array($this->pessoaStatus))
256
-            $this->pessoaStatus = SerializerHelper::denormalize($this->pessoaStatus, PessoaStatus::class);
255
+        if(is_array($this->pessoaStatus)) {
256
+                    $this->pessoaStatus = SerializerHelper::denormalize($this->pessoaStatus, PessoaStatus::class);
257
+        }
257 258
 
258 259
         return $this;
259 260
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/Model/ContaRecebimentoLancamento.php 1 patch
Braces   +15 added lines, -10 removed lines patch added patch discarded remove patch
@@ -105,8 +105,9 @@  discard block
 block discarded – undo
105 105
     {
106 106
         $this->contaRecebimento = $contaRecebimento;
107 107
 
108
-        if(is_array($this->contaRecebimento))
109
-            $this->contaRecebimento = SerializerHelper::denormalize($this->contaRecebimento, ContaRecebimento::class);
108
+        if(is_array($this->contaRecebimento)) {
109
+                    $this->contaRecebimento = SerializerHelper::denormalize($this->contaRecebimento, ContaRecebimento::class);
110
+        }
110 111
 
111 112
         return $this;
112 113
     }
@@ -127,8 +128,9 @@  discard block
 block discarded – undo
127 128
     {
128 129
         $this->contaPayLancamento = $contaPayLancamento;
129 130
 
130
-        if(is_array($this->contaPayLancamento))
131
-            $this->contaPayLancamento = SerializerHelper::denormalize($this->contaPayLancamento, ContaPayLancamento::class);
131
+        if(is_array($this->contaPayLancamento)) {
132
+                    $this->contaPayLancamento = SerializerHelper::denormalize($this->contaPayLancamento, ContaPayLancamento::class);
133
+        }
132 134
 
133 135
         return $this;
134 136
     }
@@ -149,8 +151,9 @@  discard block
 block discarded – undo
149 151
     {
150 152
         $this->pagamento = $pagamento;
151 153
 
152
-        if(is_array($this->pagamento))
153
-            $this->pagamento = SerializerHelper::denormalize($this->pagamento, Pagamento::class);
154
+        if(is_array($this->pagamento)) {
155
+                    $this->pagamento = SerializerHelper::denormalize($this->pagamento, Pagamento::class);
156
+        }
154 157
 
155 158
         return $this;
156 159
     }
@@ -171,8 +174,9 @@  discard block
 block discarded – undo
171 174
     {
172 175
         $this->lancamentoTipo = $lancamentoTipo;
173 176
 
174
-        if(is_array($this->lancamentoTipo))
175
-            $this->lancamentoTipo = SerializerHelper::denormalize($this->lancamentoTipo, LancamentoTipo::class);
177
+        if(is_array($this->lancamentoTipo)) {
178
+                    $this->lancamentoTipo = SerializerHelper::denormalize($this->lancamentoTipo, LancamentoTipo::class);
179
+        }
176 180
 
177 181
         return $this;
178 182
     }
@@ -283,8 +287,9 @@  discard block
 block discarded – undo
283 287
     {
284 288
         $this->intencaoVenda = $intencaoVenda;
285 289
 
286
-        if(is_array($this->intencaoVenda))
287
-            $this->intencaoVenda = SerializerHelper::denormalize($this->intencaoVenda, IntencaoVenda::class);
290
+        if(is_array($this->intencaoVenda)) {
291
+                    $this->intencaoVenda = SerializerHelper::denormalize($this->intencaoVenda, IntencaoVenda::class);
292
+        }
288 293
 
289 294
         return $this;
290 295
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/API/ProdutoApi.php 1 patch
Braces   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -41,10 +41,10 @@
 block discarded – undo
41 41
                 $response->json(),
42 42
                 Contracts\Produto\GetByAtivosByPessoaIdResponse::class
43 43
             );
44
-        }catch (RequestException $ex) {
44
+        } catch (RequestException $ex) {
45 45
             $responseBody = $ex->getResponse()->json();
46 46
             throw new \Exception($responseBody['message']);
47
-        }catch (\Exception $ex){
47
+        } catch (\Exception $ex){
48 48
             throw new \Exception($ex->getMessage(), $ex->getCode(), $ex);
49 49
         }
50 50
     }
Please login to merge, or discard this patch.
src/Integracao/ControlPay/API/LoginApi.php 1 patch
Braces   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -40,10 +40,10 @@  discard block
 block discarded – undo
40 40
                 $response->json(),
41 41
                 Contracts\Login\LoginResponse::class
42 42
             );
43
-        }catch (RequestException $ex) {
43
+        } catch (RequestException $ex) {
44 44
             $responseBody = $ex->getResponse()->json();
45 45
             throw new \Exception($responseBody['message']);
46
-        }catch (\Exception $ex){
46
+        } catch (\Exception $ex){
47 47
             throw new \Exception($ex->getMessage(), $ex->getCode(), $ex);
48 48
         }
49 49
     }
@@ -58,10 +58,10 @@  discard block
 block discarded – undo
58 58
             $this->_httpClient->post(__FUNCTION__,[]);
59 59
 
60 60
             return true;
61
-        }catch (RequestException $ex) {
61
+        } catch (RequestException $ex) {
62 62
             $responseBody = $ex->getResponse()->json();
63 63
             throw new \Exception($responseBody['message']);
64
-        }catch (\Exception $ex){
64
+        } catch (\Exception $ex){
65 65
             throw new \Exception($ex->getMessage(), $ex->getCode(), $ex);
66 66
         }
67 67
     }
@@ -82,10 +82,10 @@  discard block
 block discarded – undo
82 82
                 $response->json(),
83 83
                 Contracts\Login\ConsultaLoginResponse::class
84 84
             );
85
-        }catch (RequestException $ex) {
85
+        } catch (RequestException $ex) {
86 86
             $responseBody = $ex->getResponse()->json();
87 87
             throw new \Exception($responseBody['message']);
88
-        }catch (\Exception $ex){
88
+        } catch (\Exception $ex){
89 89
             throw new \Exception($ex->getMessage(), $ex->getCode(), $ex);
90 90
         }
91 91
     }
Please login to merge, or discard this patch.