Conditions | 3 |
Paths | 3 |
Total Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Tests | 7 |
CRAP Score | 3 |
Changes | 0 |
1 | <?php |
||
43 | 9 | protected function parseAttributes($attributes) |
|
44 | { |
||
45 | 9 | $result = []; |
|
46 | 9 | if (is_array($attributes)) { |
|
47 | 6 | foreach ($attributes as $key => $field) { |
|
48 | 6 | $result[] = $this->model->getAttribute($field); |
|
49 | } |
||
50 | } else { |
||
51 | 3 | return $this->model->getAttribute($attributes); |
|
52 | } |
||
53 | |||
54 | 6 | return $result; |
|
55 | } |
||
56 | |||
69 |