Completed
Push — master ( 01ea62...c1ef80 )
by Naylon Kessler de
02:30
created
src/SmartCNAB/Services/Factory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -39,7 +39,7 @@
 block discarded – undo
39 39
      */
40 40
     public function returning($path, $bank = null)
41 41
     {
42
-        $bank = $bank?: Inspector::bankNumberOf($path);
42
+        $bank = $bank ?: Inspector::bankNumberOf($path);
43 43
         $bankNs = $this->discoverBankNamespace($bank, 'Returning');
44 44
         $version = Inspector::fileVersionOf($path);
45 45
         $file = "File{$version}";
Please login to merge, or discard this patch.
src/SmartCNAB/Support/Picture.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -96,7 +96,7 @@
 block discarded – undo
96 96
     {
97 97
         $parsed = array_merge([
98 98
             'data-type' => 'numeric',
99
-            'info-type' => empty($meta['type'])? 'generic' : $meta['type'],
99
+            'info-type' => empty($meta['type']) ? 'generic' : $meta['type'],
100 100
             'strict' => true,
101 101
         ], $meta);
102 102
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -213,7 +213,9 @@
 block discarded – undo
213 213
      */
214 214
     protected function toDefault($value, array $meta = [])
215 215
     {
216
-        if ( ! empty($value)) return $value;
216
+        if ( ! empty($value)) {
217
+            return $value;
218
+        }
217 219
 
218 220
         if ( ! empty($meta['def'])) {
219 221
             $value = $meta['def'];
Please login to merge, or discard this patch.
src/SmartCNAB/Support/File/Remittance.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -140,7 +140,7 @@
 block discarded – undo
140 140
      */
141 141
     protected function getFormatMapper(array $data, $type)
142 142
     {
143
-        return function ($meta, $field) use ($data, $type) {
143
+        return function($meta, $field) use ($data, $type) {
144 144
             $value = empty($data[$field]) ? '' : $data[$field];
145 145
             $method = 'mutate' . ucfirst($type) . ucfirst($field);
146 146
 
Please login to merge, or discard this patch.
src/SmartCNAB/Support/File/File.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -100,7 +100,7 @@
 block discarded – undo
100 100
      */
101 101
     protected function generate()
102 102
     {
103
-        $lines = array_map(function ($line) {
103
+        $lines = array_map(function($line) {
104 104
             return implode('', $line);
105 105
         }, $this->getLines());
106 106
 
Please login to merge, or discard this patch.
src/SmartCNAB/Support/File/Returning.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -47,7 +47,7 @@  discard block
 block discarded – undo
47 47
     {
48 48
         $details = array_slice($this->lines, 1, count($this->lines) - 2);
49 49
 
50
-        return array_map(function ($detail) {
50
+        return array_map(function($detail) {
51 51
             return (object) $this->parseLine($detail);
52 52
         }, $details);
53 53
     }
@@ -94,7 +94,7 @@  discard block
 block discarded – undo
94 94
      */
95 95
     protected function getParseMapper($data)
96 96
     {
97
-        return function ($meta) use ($data) {
97
+        return function($meta) use ($data) {
98 98
             return $this->picture->from($meta['pic'], $data, $meta);
99 99
         };
100 100
     }
Please login to merge, or discard this patch.
src/SmartCNAB/Services/Remittances/Banks/BancoDoBrasil/File400.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -85,7 +85,7 @@  discard block
 block discarded – undo
85 85
      *
86 86
      * @param  mixed  $value
87 87
      * @param  array  $data
88
-     * @return mixed
88
+     * @return integer
89 89
      */
90 90
     protected function mutateDetailCompanyDocumentType(
91 91
         $value,
@@ -113,7 +113,7 @@  discard block
 block discarded – undo
113 113
      *
114 114
      * @param  mixed  $value
115 115
      * @param  array  $data
116
-     * @return mixed
116
+     * @return integer
117 117
      */
118 118
     protected function mutateDetailDocumentType(
119 119
         $value,
Please login to merge, or discard this patch.
Braces   +12 added lines, -4 removed lines patch added patch discarded remove patch
@@ -133,7 +133,9 @@  discard block
 block discarded – undo
133 133
         $value,
134 134
         array $data = []
135 135
     ) {
136
-        if (empty($data['account'])) return $value;
136
+        if (empty($data['account'])) {
137
+            return $value;
138
+        }
137 139
 
138 140
         return $value ?: $data['account'];
139 141
     }
@@ -149,7 +151,9 @@  discard block
 block discarded – undo
149 151
         $value,
150 152
         array $data = []
151 153
     ) {
152
-        if (empty($data['account'])) return $value;
154
+        if (empty($data['account'])) {
155
+            return $value;
156
+        }
153 157
 
154 158
         return $value ?: $data['accountDv'];
155 159
     }
@@ -165,7 +169,9 @@  discard block
 block discarded – undo
165 169
         $value,
166 170
         array $data = []
167 171
     ) {
168
-        if (empty($data['branch'])) return $value;
172
+        if (empty($data['branch'])) {
173
+            return $value;
174
+        }
169 175
 
170 176
         return $value ?: $data['branch'];
171 177
     }
@@ -181,7 +187,9 @@  discard block
 block discarded – undo
181 187
         $value,
182 188
         array $data = []
183 189
     ) {
184
-        if (empty($data['branch'])) return $value;
190
+        if (empty($data['branch'])) {
191
+            return $value;
192
+        }
185 193
 
186 194
         return $value ?: $data['branchDv'];
187 195
     }
Please login to merge, or discard this patch.
src/SmartCNAB/Services/Remittances/Banks/Bradesco/File400.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -35,7 +35,7 @@
 block discarded – undo
35 35
      *
36 36
      * @param  mixed  $value
37 37
      * @param  array  $data
38
-     * @return mixed
38
+     * @return integer
39 39
      */
40 40
     protected function mutateDetailLateInterestFlag(
41 41
         $value,
Please login to merge, or discard this patch.
src/SmartCNAB/Services/Remittances/Banks/Caixa/File400.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
      *
23 23
      * @param  mixed  $value
24 24
      * @param  array  $data
25
-     * @return mixed
25
+     * @return integer
26 26
      */
27 27
     protected function mutateDetailCompanyDocumentType(
28 28
         $value,
@@ -50,7 +50,7 @@  discard block
 block discarded – undo
50 50
      *
51 51
      * @param  mixed  $value
52 52
      * @param  array  $data
53
-     * @return mixed
53
+     * @return integer
54 54
      */
55 55
     protected function mutateDetailDocumentType(
56 56
         $value,
Please login to merge, or discard this patch.
Braces   +9 added lines, -3 removed lines patch added patch discarded remove patch
@@ -70,9 +70,13 @@  discard block
 block discarded – undo
70 70
         $value,
71 71
         array $data = []
72 72
     ) {
73
-        if ($data['occurrenceCode'] == 11) return Caixa::INST_PROTEST;
73
+        if ($data['occurrenceCode'] == 11) {
74
+            return Caixa::INST_PROTEST;
75
+        }
74 76
 
75
-        if ($data['occurrenceCode'] == 12) return Caixa::INST_DEVOLUTION;
77
+        if ($data['occurrenceCode'] == 12) {
78
+            return Caixa::INST_DEVOLUTION;
79
+        }
76 80
 
77 81
         return $value;
78 82
     }
@@ -90,7 +94,9 @@  discard block
 block discarded – undo
90 94
     ) {
91 95
         $returnValue = $value == '' && $data['occurrenceCode'] == 9;
92 96
 
93
-        if ($returnValue) return $value;
97
+        if ($returnValue) {
98
+            return $value;
99
+        }
94 100
 
95 101
         return $value ?: $data['expiration']->add(new \DateInterval('P1D'));
96 102
     }
Please login to merge, or discard this patch.
src/SmartCNAB/Services/Remittances/Banks/Itau/File400.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
      *
73 73
      * @param  mixed  $value
74 74
      * @param  array  $data
75
-     * @return mixed
75
+     * @return integer
76 76
      */
77 77
     protected function mutateDetailCompanyDocumentType(
78 78
         $value,
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
      *
101 101
      * @param  mixed  $value
102 102
      * @param  array  $data
103
-     * @return mixed
103
+     * @return integer
104 104
      */
105 105
     protected function mutateDetailDocumentType(
106 106
         $value,
Please login to merge, or discard this patch.
Braces   +6 added lines, -2 removed lines patch added patch discarded remove patch
@@ -166,7 +166,9 @@  discard block
 block discarded – undo
166 166
         $value,
167 167
         array $data = []
168 168
     ) {
169
-        if (empty($data['account'])) return $value;
169
+        if (empty($data['account'])) {
170
+            return $value;
171
+        }
170 172
 
171 173
         return $value ?: $data['account'];
172 174
     }
@@ -182,7 +184,9 @@  discard block
 block discarded – undo
182 184
         $value,
183 185
         array $data = []
184 186
     ) {
185
-        if (empty($data['accountDv'])) return $value;
187
+        if (empty($data['accountDv'])) {
188
+            return $value;
189
+        }
186 190
 
187 191
         return $value ?: $data['accountDv'];
188 192
     }
Please login to merge, or discard this patch.