From 263a7024ce40a57cab6d39cc7dd24b050c2c7e75 Mon Sep 17 00:00:00 2001
From: Demian Katz <demian.katz@villanova.edu>
Date: Tue, 4 Sep 2012 11:56:17 -0400
Subject: [PATCH] Fix for removal of Paginator::factory() from framework.

---
 module/VuFind/src/VuFind/Search/Base/Results.php | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/module/VuFind/src/VuFind/Search/Base/Results.php b/module/VuFind/src/VuFind/Search/Base/Results.php
index 6a533da282b..558797eccb5 100644
--- a/module/VuFind/src/VuFind/Search/Base/Results.php
+++ b/module/VuFind/src/VuFind/Search/Base/Results.php
@@ -409,10 +409,12 @@ abstract class Results
         }
 
         // Build the standard paginator control:
-        return Paginator::factory($total)
-            ->setCurrentPageNumber($this->getParams()->getPage())
+        $adapter = new \Zend\Paginator\Adapter\Null($total);
+        $paginator = new Paginator($adapter);
+        $paginator->setCurrentPageNumber($this->getParams()->getPage())
             ->setItemCountPerPage($this->getParams()->getLimit())
             ->setPageRange(11);
+        return $paginator;
     }
 
     /**
-- 
GitLab