Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/Paginator.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
use Zend\Cache\Storage\IteratorInterface as CacheIterator;
use Zend\Cache\Storage\StorageInterface as CacheStorage;
use Zend\Db\Sql;
use Zend\Db\ResultSet\AbstractResultSet;
use Zend\Filter\FilterInterface;
use Zend\Json\Json;
use Zend\Paginator\Adapter\AdapterInterface;
Expand Down Expand Up @@ -826,7 +827,7 @@ public function toJson()
{
$currentItems = $this->getCurrentItems();

if ($currentItems instanceof DbAbstractRowset) {
if ($currentItems instanceof AbstractResultSet) {
return Json::encode($currentItems->toArray());
}
return Json::encode($currentItems);
Expand Down Expand Up @@ -891,7 +892,7 @@ protected function _calculatePageCount()
* Creates the page collection.
*
* @param string $scrollingStyle Scrolling style
* @return stdClass
* @return \stdClass
*/
protected function _createPages($scrollingStyle = null)
{
Expand Down

0 comments on commit 9bb9d9a

Please sign in to comment.