Conditions | 3 |
Paths | 3 |
Total Lines | 15 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Tests | 12 |
CRAP Score | 3 |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
24 | 1 | public function get($response) |
|
25 | { |
||
26 | 1 | $json = $this->decode($response); |
|
27 | 1 | $header = array_shift($json); |
|
28 | 1 | $result = array(); |
|
29 | 1 | foreach ($json as $row) { |
|
30 | 1 | $work = array(); |
|
31 | 1 | foreach ($row as $key => $value) { |
|
32 | 1 | $work[$header[$key]] = $value; |
|
33 | 1 | } |
|
34 | 1 | $result[] = $work; |
|
35 | 1 | } |
|
36 | |||
37 | 1 | return $result; |
|
38 | } |
||
39 | } |
||
40 |