We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent df425c5 commit d23af96Copy full SHA for d23af96
src/ORM/ResultSet.php
@@ -170,8 +170,9 @@ public function next()
170
public function rewind()
171
{
172
$this->index = 0;
173
- $this->chunkIndex = 0;
174
$this->page = 1;
+ $this->chunkIndex = 0;
175
+ $this->chunkSize = 0;
176
}
177
178
/**
@@ -188,6 +189,10 @@ public function valid()
188
189
190
191
if ($this->chunkSize && $this->chunkIndex >= $this->chunkSize) {
192
+ if ($this->chunkIndex < $this->getConfig('size')) {
193
+ return false;
194
+ }
195
+
196
$this->page++;
197
$this->fetchChunk();
198
0 commit comments