Skip to content

Commit

Permalink
Update CallableDecoratorAdapter.php (#63)
Browse files Browse the repository at this point in the history
  • Loading branch information
lakiboy committed Dec 6, 2021
1 parent b229ed5 commit a1726e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Pagerfanta/CallableDecoratorAdapter.php
Expand Up @@ -26,7 +26,7 @@ public function getNbResults(): int
public function getSlice($offset, $length): array
{
$items = $this->adapter->getSlice($offset, $length);
$items = $items instanceof Traversable ? iterator_to_array($items) : $items;
$items = $items instanceof Traversable ? iterator_to_array($items, false) : $items;

return array_map($this->callback, $items);
}
Expand Down

0 comments on commit a1726e6

Please sign in to comment.