Completed
Push — master ( 81a81c...9e4e8e )
by Roberto
02:54 queued 30s
created
src/Tools.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -194,7 +194,7 @@
 block discarded – undo
194 194
         }
195 195
         foreach ($eventos as $evt) {
196 196
             //verifica se o evento pertence ao grupo indicado
197
-            if (! in_array($evt->alias(), $this->grupos[$grupo])) {
197
+            if (!in_array($evt->alias(), $this->grupos[$grupo])) {
198 198
                 throw new RuntimeException(
199 199
                     'O evento ' . $evt->alias() . ' não pertence a este grupo [ '
200 200
                     . $this->eventGroup[$grupo] . ' ].'
Please login to merge, or discard this patch.
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -662,6 +662,9 @@
 block discarded – undo
662 662
         }
663 663
     }
664 664
     
665
+    /**
666
+     * @param string $request
667
+     */
665 668
     protected function sign($request)
666 669
     {
667 670
         return str_replace(
Please login to merge, or discard this patch.
src/Factories/EvtAltContratual.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         $this->dom->addChild(
77 77
             $ideEvento,
78 78
             "nrRecibo",
79
-            ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
79
+            !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
80 80
             false
81 81
         );
82 82
         $this->dom->addChild(
Please login to merge, or discard this patch.
src/Factories/EvtAltCadastral.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         $this->dom->addChild(
77 77
             $ideEvento,
78 78
             "nrRecibo",
79
-            ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
79
+            !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
80 80
             false
81 81
         );
82 82
         $this->dom->addChild(
Please login to merge, or discard this patch.
src/Factories/EvtCAT.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         $this->dom->addChild(
77 77
             $ideEvento,
78 78
             "nrRecibo",
79
-            ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
79
+            !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
80 80
             false
81 81
         );
82 82
         $this->dom->addChild(
Please login to merge, or discard this patch.
src/Factories/EvtTSVTermino.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         $this->dom->addChild(
77 77
             $ideEvento,
78 78
             "nrRecibo",
79
-            ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
79
+            !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
80 80
             false
81 81
         );
82 82
         $this->dom->addChild(
Please login to merge, or discard this patch.
src/Factories/EvtTSVInicio.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -76,7 +76,7 @@
 block discarded – undo
76 76
         $this->dom->addChild(
77 77
             $ideEvento,
78 78
             "nrRecibo",
79
-            ! empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
79
+            !empty($this->std->nrrecibo) ? $this->std->nrrecibo : null,
80 80
             false
81 81
         );
82 82
         $this->dom->addChild(
Please login to merge, or discard this patch.
src/Common/Factory.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -120,7 +120,7 @@  discard block
 block discarded – undo
120 120
         //set properties from config
121 121
         $stdConf    = json_decode($config);
122 122
         $this->date = new DateTime();
123
-        if (! empty($date)) {
123
+        if (!empty($date)) {
124 124
             $this->date = new DateTime($date);
125 125
         }
126 126
         $this->tpAmb = $stdConf->tpAmb;
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
         $this->nmRazao = $stdConf->empregador->nmRazao;
132 132
         $this->layoutStr = $this->strLayoutVer($this->layout);
133 133
         $this->certificate = $certificate;
134
-        if (empty($std) || ! is_object($std)) {
134
+        if (empty($std) || !is_object($std)) {
135 135
             throw new \InvalidArgumentException(
136 136
                 'Você deve passar os parâmetros num stdClass.'
137 137
             );
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
         $fils = explode('.', $layout);
170 170
         $str  = 'v';
171 171
         foreach ($fils as $fil) {
172
-            $str .= str_pad($fil, 2, '0', STR_PAD_LEFT).'_';
172
+            $str .= str_pad($fil, 2, '0', STR_PAD_LEFT) . '_';
173 173
         }
174 174
         return substr($str, 0, -1);
175 175
     }
@@ -201,12 +201,12 @@  discard block
 block discarded – undo
201 201
      */
202 202
     protected function validInputData($data)
203 203
     {
204
-        if (! is_file($this->jsonschema)) {
204
+        if (!is_file($this->jsonschema)) {
205 205
             return true;
206 206
         }
207 207
         $validator = new JsonValid();
208
-        $validator->check($data, (object) ['$ref' => 'file://'.$this->jsonschema]);
209
-        if (! $validator->isValid()) {
208
+        $validator->check($data, (object) ['$ref' => 'file://' . $this->jsonschema]);
209
+        if (!$validator->isValid()) {
210 210
             $msg = "JSON does not validate. Violations:\n";
211 211
             foreach ($validator->getErrors() as $error) {
212 212
                 $msg .= sprintf("[%s] %s\n", $error['property'], $error['message']);
@@ -363,7 +363,7 @@  discard block
 block discarded – undo
363 363
      */
364 364
     public function standardizeProperties(stdClass $data)
365 365
     {
366
-        if (! is_file($this->jsonschema)) {
366
+        if (!is_file($this->jsonschema)) {
367 367
             return $data;
368 368
         }
369 369
         $jsonSchemaObj = json_decode(file_get_contents($this->jsonschema));
@@ -378,7 +378,7 @@  discard block
 block discarded – undo
378 378
     {
379 379
         $xml = $this->dom->saveXML($this->eSocial);
380 380
         $xml = Strings::clearXmlString($xml);
381
-        if (! empty($this->certificate)) {
381
+        if (!empty($this->certificate)) {
382 382
             $xml = Signer::sign(
383 383
                 $this->certificate,
384 384
                 $xml,
Please login to merge, or discard this patch.
src/Factories/EvtIrrfBenef.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
         $this->dom->addChild(
70 70
             $ideEvento,
71 71
             "nrRecArqBase",
72
-            ! empty($this->std->nrrecarqbase) ? $this->std->nrrecarqbase : null,
72
+            !empty($this->std->nrrecarqbase) ? $this->std->nrrecarqbase : null,
73 73
             false
74 74
         );
75 75
         $this->dom->addChild(
@@ -87,7 +87,7 @@  discard block
 block discarded – undo
87 87
             true
88 88
         );
89 89
         $this->node->appendChild($ideTrabalhador);
90
-        if (! empty($this->std->vrdeddep)) {
90
+        if (!empty($this->std->vrdeddep)) {
91 91
             $infoDep = $this->dom->createElement("infoDep");
92 92
             $this->dom->addChild(
93 93
                 $infoDep,
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
             $this->dom->addChild(
103 103
                 $infoIrrf,
104 104
                 "codCateg",
105
-                ! empty($nIrrf->codcateg) ? $nIrrf->codcateg : null,
105
+                !empty($nIrrf->codcateg) ? $nIrrf->codcateg : null,
106 106
                 false
107 107
             );
108 108
             $this->dom->addChild(
@@ -161,7 +161,7 @@  discard block
 block discarded – undo
161 161
                 $this->dom->addChild(
162 162
                     $idePais,
163 163
                     "nifBenef",
164
-                    ! empty($nIrrf->idepgtoext->nifbenef) ? $nIrrf->idepgtoext->nifbenef : null,
164
+                    !empty($nIrrf->idepgtoext->nifbenef) ? $nIrrf->idepgtoext->nifbenef : null,
165 165
                     false
166 166
                 );
167 167
                 $idePgtoExt->appendChild($idePais);
@@ -176,19 +176,19 @@  discard block
 block discarded – undo
176 176
                 $this->dom->addChild(
177 177
                     $endExt,
178 178
                     "nrLograd",
179
-                    ! empty($nIrrf->idepgtoext->nrlograd) ? $nIrrf->idepgtoext->nrlograd : null,
179
+                    !empty($nIrrf->idepgtoext->nrlograd) ? $nIrrf->idepgtoext->nrlograd : null,
180 180
                     false
181 181
                 );
182 182
                 $this->dom->addChild(
183 183
                     $endExt,
184 184
                     "complem",
185
-                    ! empty($nIrrf->idepgtoext->complem) ? $nIrrf->idepgtoext->complem : null,
185
+                    !empty($nIrrf->idepgtoext->complem) ? $nIrrf->idepgtoext->complem : null,
186 186
                     false
187 187
                 );
188 188
                 $this->dom->addChild(
189 189
                     $endExt,
190 190
                     "bairro",
191
-                    ! empty($nIrrf->idepgtoext->bairro) ? $nIrrf->idepgtoext->bairro : null,
191
+                    !empty($nIrrf->idepgtoext->bairro) ? $nIrrf->idepgtoext->bairro : null,
192 192
                     false
193 193
                 );
194 194
                 $this->dom->addChild(
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
                 $this->dom->addChild(
201 201
                     $endExt,
202 202
                     "codPostal",
203
-                    ! empty($nIrrf->idepgtoext->codpostal) ? $nIrrf->idepgtoext->codpostal : null,
203
+                    !empty($nIrrf->idepgtoext->codpostal) ? $nIrrf->idepgtoext->codpostal : null,
204 204
                     false
205 205
                 );
206 206
                 $idePgtoExt->appendChild($endExt);
Please login to merge, or discard this patch.
src/Factories/EvtFechaEvPer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
         $this->dom->addChild(
122 122
             $ideRespInf,
123 123
             "email",
124
-            ! empty($this->std->iderespinf->email) ? $this->std->iderespinf->email : null,
124
+            !empty($this->std->iderespinf->email) ? $this->std->iderespinf->email : null,
125 125
             false
126 126
         );
127 127
         $this->node->appendChild($ideRespInf);
@@ -166,7 +166,7 @@  discard block
 block discarded – undo
166 166
         $this->dom->addChild(
167 167
             $infoFech,
168 168
             "compSemMovto",
169
-            ! empty($this->std->infofech->compsemmovto) ? $this->std->infofech->compsemmovto : null,
169
+            !empty($this->std->infofech->compsemmovto) ? $this->std->infofech->compsemmovto : null,
170 170
             false
171 171
         );
172 172
         $this->node->appendChild($infoFech);
Please login to merge, or discard this patch.