Conditions | 4 |
Paths | 4 |
Total Lines | 9 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 6 |
CRAP Score | 4.0466 |
Changes | 0 |
1 | <?php |
||
20 | 14 | protected function indexRow($offset, $row) |
|
21 | { |
||
22 | 14 | $id = null; |
|
23 | 14 | if ($row instanceof Asset) { |
|
24 | $id = $row->getId(); |
||
25 | 14 | } elseif (is_array($row)) { |
|
26 | 14 | $id = isset($row[static::ID]) ? $row[static::ID] : null; |
|
27 | } |
||
28 | 14 | $this->addToIndex(static::ID, $offset, $id); |
|
29 | 14 | } |
|
31 |