diff --git a/modules/backend/widgets/Lists.php b/modules/backend/widgets/Lists.php index 2b3aa59b80..832e7a40e3 100644 --- a/modules/backend/widgets/Lists.php +++ b/modules/backend/widgets/Lists.php @@ -785,7 +785,7 @@ protected function getCurrentPageNumber($query) $currentPageNumber = intval($currentPageNumber); if ($currentPageNumber > 1) { - $count = $query->count(); + $count = $query->toBase()->getCountForPagination(); // If the current page number is higher than the amount of available pages, go to the last available page if ($count <= (($currentPageNumber - 1) * $this->recordsPerPage)) {