Conditions | 4 |
Paths | 5 |
Total Lines | 17 |
Code Lines | 8 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 20 |
Changes | 0 |
1 | <?php |
||
22 | public function lastKey() |
||
23 | { |
||
24 | $after = $this->last(); |
||
25 | |||
26 | if (empty($after)) { |
||
27 | return null; |
||
28 | } |
||
29 | |||
30 | $afterKey = $after->getKeys(); |
||
31 | |||
32 | $attributes = $this->conditionIndex ? $this->conditionIndex->columns() : []; |
||
33 | |||
34 | foreach ($attributes as $attribute) { |
||
35 | $afterKey[$attribute] = $after->getAttribute($attribute); |
||
36 | } |
||
37 | |||
38 | return $afterKey; |
||
39 | } |
||
41 |