Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
31 | private function flatten(array $array, $prefix = '') |
||
32 | { |
||
33 | $result = []; |
||
34 | foreach ($array as $key => $value) { |
||
35 | if (\is_array($value)) { |
||
36 | $result = $result + $this->flatten($value, $prefix.$key.'.'); |
||
37 | } else { |
||
38 | $result[$prefix.$key] = $value; |
||
39 | } |
||
40 | } |
||
41 | |||
42 | return $result; |
||
43 | } |
||
44 | } |
||
45 |