| Conditions | 2 |
| Paths | 2 |
| Total Lines | 12 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 6 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 29 | 8 | public function getIterator() |
|
| 30 | { |
||
| 31 | 8 | if ($this->pagination->isActive()): |
|
| 32 | |||
| 33 | 4 | $offset = $this->calculateOffset(); |
|
| 34 | 4 | $length = $this->calculateLength(); |
|
| 35 | 4 | return new \LimitIterator( new \IteratorIterator($this->items), $offset, $length); |
|
| 36 | |||
| 37 | endif; |
||
| 38 | |||
| 39 | 4 | return $this->items; |
|
| 40 | } |
||
| 41 | |||
| 64 | } |
Our type inference engine has found an assignment to a property that is incompatible with the declared type of that property.
Either this assignment is in error or the assigned type should be added to the documentation/type hint for that property..