Skip to content

Commit 09e131b

Browse files
authored
Fix rendundant query to database
If there was zero results
1 parent bd5add0 commit 09e131b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/QueryObjectDataSource.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public function setLimitCallback($callback) {
8484
}
8585

8686
protected function getResultSet(int $page = 1, ?int $itemsPerPage = null) {
87-
if (!$this->resultSet) {
87+
if ($this->resultSet === null) {
8888
$this->resultSet = $itemsPerPage
8989
? iterator_to_array($this->queryObject->getResultSet($page, $itemsPerPage)->getIterator())
9090
: $this->queryObject->getQuery()->getResult();

0 commit comments

Comments
 (0)