Test Setup Failed
Push — master ( 947c79...20ba58 )
by
unknown
34s queued 10s
created
src/Complements.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,6 @@
 block discarded – undo
2 2
 
3 3
 namespace NFePHP\CTe;
4 4
 
5
-use NFePHP\Common\Strings;
6 5
 use NFePHP\CTe\Common\Standardize;
7 6
 use NFePHP\CTe\Exception\DocumentsException;
8 7
 use DOMDocument;
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@  discard block
 block discarded – undo
25 25
             //wrong document, this document is not able to recieve a protocol
26 26
             throw DocumentsException::wrongDocument(0, $key);
27 27
         }
28
-        $func = "add".$key."Protocol";
28
+        $func = "add" . $key . "Protocol";
29 29
         return self::$func($request, $response);
30 30
     }
31 31
     
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
             throw DocumentsException::wrongDocument(3, "<protCTe>");
129 129
         }
130 130
         $infProt = $ret->getElementsByTagName('infProt')->item(0);
131
-        $cStat  = $infProt->getElementsByTagName('cStat')->item(0)->nodeValue;
131
+        $cStat = $infProt->getElementsByTagName('cStat')->item(0)->nodeValue;
132 132
         $xMotivo = $infProt->getElementsByTagName('xMotivo')->item(0)->nodeValue;
133 133
         $dig = $infProt->getElementsByTagName("digVal")->item(0);
134 134
         $digProt = '000';
@@ -185,7 +185,7 @@  discard block
 block discarded – undo
185 185
             throw DocumentsException::wrongDocument(3, "<protCTe>");
186 186
         }
187 187
         $infProt = $ret->getElementsByTagName('infProt')->item(0);
188
-        $cStat  = $infProt->getElementsByTagName('cStat')->item(0)->nodeValue;
188
+        $cStat = $infProt->getElementsByTagName('cStat')->item(0)->nodeValue;
189 189
         $xMotivo = $infProt->getElementsByTagName('xMotivo')->item(0)->nodeValue;
190 190
         $dig = $infProt->getElementsByTagName("digVal")->item(0);
191 191
         $digProt = '000';
@@ -238,7 +238,7 @@  discard block
 block discarded – undo
238 238
 //        $resLote = $ret->getElementsByTagName('idLote')->item(0)->nodeValue;
239 239
         //extrai a rag retEvento da resposta (retorno da SEFAZ)
240 240
         $retEv = $ret->getElementsByTagName('retEventoCTe')->item(0);
241
-        $cStat  = $retEv->getElementsByTagName('cStat')->item(0)->nodeValue;
241
+        $cStat = $retEv->getElementsByTagName('cStat')->item(0)->nodeValue;
242 242
         $xMotivo = $retEv->getElementsByTagName('xMotivo')->item(0)->nodeValue;
243 243
         $tpEvento = $retEv->getElementsByTagName('tpEvento')->item(0)->nodeValue;
244 244
         $cStatValids = ['135', '136'];
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
     {
270 270
         $xml = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>"
271 271
                 . "<$nodename versao=\"$versao\" "
272
-                . "xmlns=\"".self::$urlPortal."\">";
272
+                . "xmlns=\"" . self::$urlPortal . "\">";
273 273
         $xml .= $first;
274 274
         $xml .= $second;
275 275
         $xml .= "</$nodename>";
Please login to merge, or discard this patch.
src/Factories/Parser.php 3 patches
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -777,7 +777,6 @@
 block discarded – undo
777 777
 
778 778
     /**
779 779
      * Create tag comb [LA]
780
-     * @param stdClass $std
781 780
      * @return void
782 781
      */
783 782
     protected function buildLAEntity()
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -16,7 +16,6 @@
 block discarded – undo
16 16
  * @link      http://github.com/nfephp-org/sped-nfe for the canonical source repository
17 17
  */
18 18
 
19
-use NFePHP\Common\Strings;
20 19
 use NFePHP\CTe\Make;
21 20
 use NFePHP\CTe\Exception\DocumentsException;
22 21
 use stdClass;
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
     public function __construct($version = '3.10')
108 108
     {
109 109
         $ver = str_replace('.', '', $version);
110
-        $path = realpath(__DIR__."/../../storage/txtstructure$ver.json");
110
+        $path = realpath(__DIR__ . "/../../storage/txtstructure$ver.json");
111 111
         $this->structure = json_decode(file_get_contents($path), true);
112 112
         $this->make = new Make();
113 113
     }
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
             if (empty($fields)) {
139 139
                 continue;
140 140
             }
141
-            $metodo = strtolower(str_replace(' ', '', $fields[0])).'Entity';
141
+            $metodo = strtolower(str_replace(' ', '', $fields[0])) . 'Entity';
142 142
             if (!method_exists(__CLASS__, $metodo)) {
143 143
                 //campo não definido
144 144
                 throw DocumentsException::wrongDocument(16, $lin);
@@ -158,7 +158,7 @@  discard block
 block discarded – undo
158 158
     protected static function fieldsToStd($dfls, $struct)
159 159
     {
160 160
         $sfls = explode('|', $struct);
161
-        $len = count($sfls)-1;
161
+        $len = count($sfls) - 1;
162 162
         $std = new \stdClass();
163 163
         for ($i = 1; $i < $len; $i++) {
164 164
             $name = $sfls[$i];
@@ -1231,7 +1231,7 @@  discard block
 block discarded – undo
1231 1231
         $this->stdPIS->CST = $std->CST;
1232 1232
         $this->stdPIS->vPIS = $std->vPIS;
1233 1233
         $this->stdPIS->qBCProd = $std->qBCProd;
1234
-        $this->stdPIS->vAliqProd  = $std->vAliqProd;
1234
+        $this->stdPIS->vAliqProd = $std->vAliqProd;
1235 1235
         $this->buildQEntity();
1236 1236
     }
1237 1237
 
@@ -1282,7 +1282,7 @@  discard block
 block discarded – undo
1282 1282
     protected function q10Entity($std)
1283 1283
     {
1284 1284
         $this->stdPIS->qBCProd = $std->qBCProd;
1285
-        $this->stdPIS->vAliqProd  = $std->vAliqProd;
1285
+        $this->stdPIS->vAliqProd = $std->vAliqProd;
1286 1286
         $this->buildQEntity();
1287 1287
     }
1288 1288
 
Please login to merge, or discard this patch.
src/Tools.php 3 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,6 @@
 block discarded – undo
19 19
 use NFePHP\Common\Strings;
20 20
 use NFePHP\Common\Signer;
21 21
 use NFePHP\Common\UFList;
22
-use NFePHP\CTe\Factories\Events;
23 22
 use NFePHP\CTe\Common\Tools as ToolsCommon;
24 23
 use RuntimeException;
25 24
 use InvalidArgumentException;
Please login to merge, or discard this patch.
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -92,7 +92,7 @@
 block discarded – undo
92 92
     /**
93 93
      * Request authorization to issue CTe OS with one document only
94 94
      * @param type $xml
95
-     * @return type
95
+     * @return string
96 96
      */
97 97
     public function sefazEnviaCTeOS($xml)
98 98
     {
Please login to merge, or discard this patch.
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
         if ($compactar) {
82 82
             $gzdata = base64_encode(gzencode($cons, 9, FORCE_GZIP));
83 83
             $body = "<cteDadosMsgZip xmlns=\"$this->urlNamespace\">$gzdata</cteDadosMsgZip>";
84
-            $method = $this->urlMethod."Zip";
84
+            $method = $this->urlMethod . "Zip";
85 85
             $parameters = ['cteDadosMsgZip' => $gzdata];
86 86
             $body = "<cteDadosMsgZip xmlns=\"$this->urlNamespace\">$gzdata</cteDadosMsgZip>";
87 87
         }
@@ -374,9 +374,9 @@  discard block
 block discarded – undo
374 374
         }
375 375
         //monta a consulta
376 376
         $consulta = "<distDFeInt xmlns=\"$this->urlPortal\" versao=\"$this->urlVersion\">"
377
-            . "<tpAmb>".$this->tpAmb."</tpAmb>"
377
+            . "<tpAmb>" . $this->tpAmb . "</tpAmb>"
378 378
             . "<cUFAutor>$cUF</cUFAutor>"
379
-            . "<CNPJ>".$this->config->cnpj."</CNPJ>$tagNSU</distDFeInt>";
379
+            . "<CNPJ>" . $this->config->cnpj . "</CNPJ>$tagNSU</distDFeInt>";
380 380
         //valida o xml da requisição
381 381
         $this->isValid($this->urlVersion, $consulta, 'distDFeInt');
382 382
         $this->lastRequest = $consulta;
@@ -666,7 +666,7 @@  discard block
 block discarded – undo
666 666
         $dt = new \DateTime();
667 667
         $dhEvento = $dt->format('Y-m-d\TH:i:sP');
668 668
         $sSeqEvento = str_pad($nSeqEvento, 2, "0", STR_PAD_LEFT);
669
-        $eventId = "ID".$tpEvento.$chave.$sSeqEvento;
669
+        $eventId = "ID" . $tpEvento . $chave . $sSeqEvento;
670 670
         $cOrgao = UFList::getCodeByUF($uf);
671 671
 
672 672
         $request = "<eventoCTe xmlns=\"$this->urlPortal\" versao=\"$this->urlVersion\">"
@@ -731,9 +731,9 @@  discard block
 block discarded – undo
731 731
         $tagChave = "<consChNFe><chNFe>$chave</chNFe></consChNFe>";
732 732
         //monta a consulta
733 733
         $consulta = "<distDFeInt xmlns=\"$this->urlPortal\" versao=\"$this->urlVersion\">"
734
-            . "<tpAmb>".$this->tpAmb."</tpAmb>"
734
+            . "<tpAmb>" . $this->tpAmb . "</tpAmb>"
735 735
             . "<cUFAutor>$cUF</cUFAutor>"
736
-            . "<CNPJ>".$this->config->cnpj."</CNPJ>$tagChave</distDFeInt>";
736
+            . "<CNPJ>" . $this->config->cnpj . "</CNPJ>$tagChave</distDFeInt>";
737 737
         //valida o xml da requisição
738 738
         $this->isValid($this->urlVersion, $consulta, 'distDFeInt');
739 739
         $this->lastRequest = $consulta;
@@ -785,8 +785,8 @@  discard block
 block discarded – undo
785 785
             . "<indOp>$indOp</indOp>"
786 786
             . "<raizCNPJ>$raizCNPJ</raizCNPJ>"
787 787
             . "<dadosCsc>"
788
-            . "<idCsc>".$this->config->CSCid."</idCsc>"
789
-            . "<codigoCsc>".$this->config->CSC."</codigoCsc>"
788
+            . "<idCsc>" . $this->config->CSCid . "</idCsc>"
789
+            . "<codigoCsc>" . $this->config->CSC . "</codigoCsc>"
790 790
             . "</dadosCsc>"
791 791
             . "</admCscNFCe>";
792 792
         }
@@ -817,7 +817,7 @@  discard block
 block discarded – undo
817 817
         $dom->loadXML($cte);
818 818
         //verifica a validade no webservice da SEFAZ
819 819
         $tpAmb = $dom->getElementsByTagName('tpAmb')->item(0)->nodeValue;
820
-        $infCTe  = $dom->getElementsByTagName('infCte')->item(0);
820
+        $infCTe = $dom->getElementsByTagName('infCte')->item(0);
821 821
         $chCTe = preg_replace('/[^0-9]/', '', $infCTe->getAttribute("Id"));
822 822
         $protocol = $dom->getElementsByTagName('nProt')->item(0)->nodeValue;
823 823
         $digval = $dom->getElementsByTagName('DigestValue')->item(0)->nodeValue;
Please login to merge, or discard this patch.
src/Common/Config.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -48,9 +48,9 @@
 block discarded – undo
48 48
      */
49 49
     protected static function validInputData(stdClass $data)
50 50
     {
51
-        $filejsonschema = __DIR__. "/../../storage/config_json.schema";
51
+        $filejsonschema = __DIR__ . "/../../storage/config_json.schema";
52 52
         $validator = new JsonValid();
53
-        $validator->check($data, (object)['$ref' => 'file://' . $filejsonschema]);
53
+        $validator->check($data, (object) ['$ref' => 'file://' . $filejsonschema]);
54 54
         if (!$validator->isValid()) {
55 55
             $msg = "";
56 56
             foreach ($validator->getErrors() as $error) {
Please login to merge, or discard this patch.
src/Common/ValidTXT.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@  discard block
 block discarded – undo
30 30
     {
31 31
         $path = realpath(__DIR__ . "/../../storage");
32 32
         $json = file_get_contents(
33
-            $path . '/txtstructure' . ($version*100) . '.json'
33
+            $path . '/txtstructure' . ($version * 100) . '.json'
34 34
         );
35 35
         self::$entities = json_decode($json, true);
36 36
     }
@@ -81,7 +81,7 @@  discard block
 block discarded – undo
81 81
             if ($default != $count) {
82 82
                 self::$errors[] = "ERRO: O número de parâmetros na linha "
83 83
                     . "está errado (esperado #$default) -> (encontrado #$count). [ $row ] Esperado [ "
84
-                    . self::$entities[$ref]." ]";
84
+                    . self::$entities[$ref] . " ]";
85 85
             }
86 86
             foreach ($fields as $field) {
87 87
                 if ($field != trim($field)) {
Please login to merge, or discard this patch.
src/Make.php 2 patches
Doc Comments   +12 added lines, -6 removed lines patch added patch discarded remove patch
@@ -1056,7 +1056,6 @@  discard block
 block discarded – undo
1056 1056
      * e adiciona ao grupo ide
1057 1057
      * #35
1058 1058
      * Nível: 2
1059
-     * @param string $toma Tomador do Serviço
1060 1059
      * @param stdClass $std
1061 1060
      * @return \DOMElement
1062 1061
      */
@@ -1748,6 +1747,7 @@  discard block
 block discarded – undo
1748 1747
      * Os parâmetros para esta função são todos os elementos da tag "ObsCont" do
1749 1748
      * tipo elemento (Ele = E|CE|A) e nível 3
1750 1749
      *
1750
+     * @param stdClass $std
1751 1751
      * @return boolean
1752 1752
      */
1753 1753
     public function tagobsCont($std)
@@ -1781,6 +1781,7 @@  discard block
 block discarded – undo
1781 1781
      * Os parâmetros para esta função são todos os elementos da tag "ObsFisco" do tipo
1782 1782
      * elemento (Ele = E|CE|A) e nível 3
1783 1783
      *
1784
+     * @param stdClass $std
1784 1785
      * @return boolean
1785 1786
      */
1786 1787
     public function tagobsFisco($std)
@@ -1814,6 +1815,7 @@  discard block
 block discarded – undo
1814 1815
      * Os parâmetros para esta função são todos os elementos da tag "emit" do
1815 1816
      * tipo elemento (Ele = E|CE|A) e nível 2
1816 1817
      *
1818
+     * @param stdClass $std
1817 1819
      * @return \DOMElement
1818 1820
      */
1819 1821
     public function tagemit($std)
@@ -1865,6 +1867,7 @@  discard block
 block discarded – undo
1865 1867
      * Os parâmetros para esta função são todos os elementos da tag "enderEmit" do
1866 1868
      * tipo elemento (Ele = E|CE|A) e nível 3
1867 1869
      *
1870
+     * @param stdClass $std
1868 1871
      * @return \DOMElement
1869 1872
      */
1870 1873
     public function tagenderEmit($std)
@@ -2461,6 +2464,7 @@  discard block
 block discarded – undo
2461 2464
      * Os parâmetros para esta função são todos os elementos da tag "dest" do
2462 2465
      * tipo elemento (Ele = E|CE|A) e nível 2
2463 2466
      *
2467
+     * @param stdClass $std
2464 2468
      * @return \DOMElement
2465 2469
      */
2466 2470
     public function tagdest($std)
@@ -2550,6 +2554,7 @@  discard block
 block discarded – undo
2550 2554
      * Os parâmetros para esta função são todos os elementos da tag "enderDest" do
2551 2555
      * tipo elemento (Ele = E|CE|A) e nível 3
2552 2556
      *
2557
+     * @param stdClass $std
2553 2558
      * @return \DOMElement
2554 2559
      */
2555 2560
     public function tagenderDest($std)
@@ -2697,6 +2702,7 @@  discard block
 block discarded – undo
2697 2702
      * Informações relativas ao ICMS
2698 2703
      * #194
2699 2704
      *
2705
+     * @param stdClass $std
2700 2706
      * @return DOMElement
2701 2707
      */
2702 2708
     public function tagicms($std)
@@ -3160,6 +3166,7 @@  discard block
 block discarded – undo
3160 3166
      * Gera as tags para o elemento: "infNFe" (Informações das NF-e)
3161 3167
      * #297
3162 3168
      * Nível: 3
3169
+     * @param stdClass $std
3163 3170
      * @return mixed
3164 3171
      */
3165 3172
     public function taginfNFe($std)
@@ -3322,7 +3329,6 @@  discard block
 block discarded – undo
3322 3329
      * Gera as tags para o elemento: "infModal" (Informações do modal)
3323 3330
      * #366
3324 3331
      * Nível: 2
3325
-     * @param string $versaoModal
3326 3332
      * @return DOMElement|\DOMNode
3327 3333
      */
3328 3334
     public function taginfModal($std)
@@ -3490,7 +3496,6 @@  discard block
 block discarded – undo
3490 3496
 
3491 3497
     /**
3492 3498
      * CT-e de substituição - tomaICMS
3493
-     * @param type $std
3494 3499
      * @return type
3495 3500
      */
3496 3501
     public function tagtomaICMS()
@@ -3502,7 +3507,7 @@  discard block
 block discarded – undo
3502 3507
 
3503 3508
     /**
3504 3509
      * CT-e de substituição - NF-e
3505
-     * @param type $std
3510
+     * @param stdClass $std
3506 3511
      * @return type
3507 3512
      */
3508 3513
     public function tagrefNFe($std)
@@ -3524,7 +3529,7 @@  discard block
 block discarded – undo
3524 3529
 
3525 3530
     /**
3526 3531
      * CT-e de substituição - NF
3527
-     * @param type $std
3532
+     * @param stdClass $std
3528 3533
      * @return type
3529 3534
      */
3530 3535
     public function tagrefNF($std)
@@ -3567,7 +3572,7 @@  discard block
 block discarded – undo
3567 3572
 
3568 3573
     /**
3569 3574
      * CT-e de substituição - CT-e
3570
-     * @param type $std
3575
+     * @param stdClass $std
3571 3576
      * @return type
3572 3577
      */
3573 3578
     public function tagrefCTe($std)
@@ -3822,6 +3827,7 @@  discard block
 block discarded – undo
3822 3827
      * Nível: 1
3823 3828
      * Os parâmetros para esta função são todos os elementos da tag "autXML"
3824 3829
      *
3830
+     * @param stdClass $std
3825 3831
      * @return boolean
3826 3832
      */
3827 3833
     public function tagautXML($std)
Please login to merge, or discard this patch.
Spacing   +19 added lines, -19 removed lines patch added patch discarded remove patch
@@ -1039,7 +1039,7 @@  discard block
 block discarded – undo
1039 1039
     {
1040 1040
         $identificador = '#4 <infPercurso> - ';
1041 1041
         $this->infPercurso[] = $this->dom->createElement('infPercurso');
1042
-        $posicao = (integer)count($this->infPercurso) - 1;
1042
+        $posicao = (integer) count($this->infPercurso) - 1;
1043 1043
         $this->dom->addChild(
1044 1044
             $this->infPercurso[$posicao],
1045 1045
             'UFPer',
@@ -1556,7 +1556,7 @@  discard block
 block discarded – undo
1556 1556
     {
1557 1557
         $identificador = '#65 <pass> - ';
1558 1558
         $this->pass[] = $this->dom->createElement('pass');
1559
-        $posicao = (integer)count($this->pass) - 1;
1559
+        $posicao = (integer) count($this->pass) - 1;
1560 1560
         $this->dom->addChild(
1561 1561
             $this->pass[$posicao],
1562 1562
             'xPass',
@@ -1755,7 +1755,7 @@  discard block
 block discarded – undo
1755 1755
         $identificador = '#91 <ObsCont> - ';
1756 1756
         if (count($this->obsCont) <= 10) {
1757 1757
             $this->obsCont[] = $this->dom->createElement('ObsCont');
1758
-            $posicao = (integer)count($this->obsCont) - 1;
1758
+            $posicao = (integer) count($this->obsCont) - 1;
1759 1759
             $this->obsCont[$posicao]->setAttribute('xCampo', $std->xCampo);
1760 1760
             $this->dom->addChild(
1761 1761
                 $this->obsCont[$posicao],
@@ -1767,9 +1767,9 @@  discard block
 block discarded – undo
1767 1767
             return true;
1768 1768
         }
1769 1769
         $this->errors[] = array(
1770
-            'tag' => (string)'<ObsCont>',
1771
-            'desc' => (string)'Campo de uso livre do contribuinte',
1772
-            'erro' => (string)'Tag deve aparecer de 0 a 10 vezes'
1770
+            'tag' => (string) '<ObsCont>',
1771
+            'desc' => (string) 'Campo de uso livre do contribuinte',
1772
+            'erro' => (string) 'Tag deve aparecer de 0 a 10 vezes'
1773 1773
         );
1774 1774
         return false;
1775 1775
     }
@@ -1788,7 +1788,7 @@  discard block
 block discarded – undo
1788 1788
         $identificador = '#94 <ObsFisco> - ';
1789 1789
         if (count($this->obsFisco) <= 10) {
1790 1790
             $this->obsFisco[] = $this->dom->createElement('ObsFisco');
1791
-            $posicao = (integer)count($this->obsFisco) - 1;
1791
+            $posicao = (integer) count($this->obsFisco) - 1;
1792 1792
             $this->obsFisco[$posicao]->setAttribute('xCampo', $std->xCampo);
1793 1793
             $this->dom->addChild(
1794 1794
                 $this->obsFisco[$posicao],
@@ -1800,9 +1800,9 @@  discard block
 block discarded – undo
1800 1800
             return true;
1801 1801
         }
1802 1802
         $this->errors[] = array(
1803
-            'tag' => (string)'<ObsFisco>',
1804
-            'desc' => (string)'Campo de uso livre do contribuinte',
1805
-            'erro' => (string)'Tag deve aparecer de 0 a 10 vezes'
1803
+            'tag' => (string) '<ObsFisco>',
1804
+            'desc' => (string) 'Campo de uso livre do contribuinte',
1805
+            'erro' => (string) 'Tag deve aparecer de 0 a 10 vezes'
1806 1806
         );
1807 1807
         return false;
1808 1808
     }
@@ -2674,7 +2674,7 @@  discard block
 block discarded – undo
2674 2674
     {
2675 2675
         $identificador = '#65 <pass> - ';
2676 2676
         $this->comp[] = $this->dom->createElement('Comp');
2677
-        $posicao = (integer)count($this->comp) - 1;
2677
+        $posicao = (integer) count($this->comp) - 1;
2678 2678
         $this->dom->addChild(
2679 2679
             $this->comp[$posicao],
2680 2680
             'xNome',
@@ -3080,7 +3080,7 @@  discard block
 block discarded – undo
3080 3080
     {
3081 3081
         $identificador = '#257 <infQ> - ';
3082 3082
         $this->infQ[] = $this->dom->createElement('infQ');
3083
-        $posicao = (integer)count($this->infQ) - 1;
3083
+        $posicao = (integer) count($this->infQ) - 1;
3084 3084
         $this->dom->addChild($this->infQ[$posicao], 'cUnid', $std->cUnid, true, $identificador . 'Código da
3085 3085
             Unidade de Medida');
3086 3086
         $this->dom->addChild($this->infQ[$posicao], 'tpMed', $std->tpMed, true, $identificador . 'Tipo da Medida');
@@ -3125,7 +3125,7 @@  discard block
 block discarded – undo
3125 3125
     {
3126 3126
         $identificador = '#262 <infNF> - ';
3127 3127
         $this->infNF[] = $this->dom->createElement('infNF');
3128
-        $posicao = (integer)count($this->infNF) - 1;
3128
+        $posicao = (integer) count($this->infNF) - 1;
3129 3129
 
3130 3130
         $this->dom->addChild($this->infNF[$posicao], 'nRoma', $std->nRoma, false, $identificador . 'Número do
3131 3131
             Romaneio da NF');
@@ -3166,7 +3166,7 @@  discard block
 block discarded – undo
3166 3166
     {
3167 3167
         $identificador = '#297 <infNFe> - ';
3168 3168
         $this->infNFe[] = $this->dom->createElement('infNFe');
3169
-        $posicao = (integer)count($this->infNFe) - 1;
3169
+        $posicao = (integer) count($this->infNFe) - 1;
3170 3170
         $this->dom->addChild(
3171 3171
             $this->infNFe[$posicao],
3172 3172
             'chave',
@@ -3201,7 +3201,7 @@  discard block
 block discarded – undo
3201 3201
     {
3202 3202
         $ident = '#319 <infOutros> - ';
3203 3203
         $this->infOutros[] = $this->dom->createElement('infOutros');
3204
-        $posicao = (integer)count($this->infOutros) - 1;
3204
+        $posicao = (integer) count($this->infOutros) - 1;
3205 3205
         $this->dom->addChild($this->infOutros[$posicao], 'tpDoc', $std->tpDoc, true, $ident . 'Tipo '
3206 3206
             . 'de documento originário');
3207 3207
         $this->dom->addChild($this->infOutros[$posicao], 'descOutros', $std->descOutros, false, $ident . 'Descrição '
@@ -3226,7 +3226,7 @@  discard block
 block discarded – undo
3226 3226
     {
3227 3227
         $ident = '#319 <infDocRef> - ';
3228 3228
         $this->infDocRef[] = $this->dom->createElement('infDocRef');
3229
-        $posicao = (integer)count($this->infDocRef) - 1;
3229
+        $posicao = (integer) count($this->infDocRef) - 1;
3230 3230
         $this->dom->addChild($this->infDocRef[$posicao], 'nDoc', $std->nDoc, false, $ident . 'Número '
3231 3231
             . 'do documento');
3232 3232
         $this->dom->addChild($this->infDocRef[$posicao], 'serie', $std->serie, false, $ident . 'Série '
@@ -3249,7 +3249,7 @@  discard block
 block discarded – undo
3249 3249
     {
3250 3250
         $identificador = '#345 <emiDocAnt> - ';
3251 3251
         $this->emiDocAnt[] = $this->dom->createElement('emiDocAnt');
3252
-        $posicao = (integer)count($this->emiDocAnt) - 1;
3252
+        $posicao = (integer) count($this->emiDocAnt) - 1;
3253 3253
         if ($std->CNPJ != '') {
3254 3254
             $this->dom->addChild(
3255 3255
                 $this->emiDocAnt[$posicao],
@@ -3290,7 +3290,7 @@  discard block
 block discarded – undo
3290 3290
     {
3291 3291
         $identificador = '#358 <idDocAntEle> - ';
3292 3292
         $this->idDocAntEle[] = $this->dom->createElement('idDocAntEle');
3293
-        $posicao = (integer)count($this->idDocAntEle) - 1;
3293
+        $posicao = (integer) count($this->idDocAntEle) - 1;
3294 3294
         $this->dom->addChild($this->idDocAntEle[$posicao], 'chCTe', $std->chCTe, true, $identificador . 'Chave de '
3295 3295
             . 'Acesso do CT-e');
3296 3296
 
@@ -3308,7 +3308,7 @@  discard block
 block discarded – undo
3308 3308
     {
3309 3309
         $identificador = '#360 <seg> - ';
3310 3310
         $this->seg[] = $this->dom->createElement('seg');
3311
-        $posicao = (integer)count($this->seg) - 1;
3311
+        $posicao = (integer) count($this->seg) - 1;
3312 3312
 
3313 3313
         $this->dom->addChild($this->seg[$posicao], 'respSeg', $std->respSeg, true, $identificador . 'Responsável
3314 3314
             pelo Seguro');
Please login to merge, or discard this patch.
src/Factories/ContingencyCTe.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@
 block discarded – undo
36 36
         $dtEmi = new DateTime($ide->getElementsByTagName('dhEmi')->item(0)->nodeValue);
37 37
         $ano = $dtEmi->format('y');
38 38
         $mes = $dtEmi->format('m');
39
-        $tpEmis = (string)$contingency->tpEmis;
39
+        $tpEmis = (string) $contingency->tpEmis;
40 40
         $emit = $dom->getElementsByTagName('emit')->item(0);
41 41
         $cnpj = $emit->getElementsByTagName('CNPJ')->item(0)->nodeValue;
42 42
 
Please login to merge, or discard this patch.
src/Factories/Contingency.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@
 block discarded – undo
114 114
         $type = strtoupper(str_replace('-', '', $type));
115 115
 
116 116
         if (empty($type)) {
117
-            $type = (string)$list[$acronym];
117
+            $type = (string) $list[$acronym];
118 118
         }
119 119
         $this->config = $this->configBuild($dt->getTimestamp(), $motive, $type);
120 120
         return $this->__toString();
Please login to merge, or discard this patch.
src/Common/Tools.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -516,7 +516,7 @@
 block discarded – undo
516 516
     protected function sendRequest($request, array $parameters = [])
517 517
     {
518 518
         $this->checkSoap();
519
-        return (string)$this->soap->send(
519
+        return (string) $this->soap->send(
520 520
             $this->urlService,
521 521
             $this->urlMethod,
522 522
             $this->urlAction,
Please login to merge, or discard this patch.