aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/ApiBundle/Controller/EntryRestController.php
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag/ApiBundle/Controller/EntryRestController.php')
-rw-r--r--src/Wallabag/ApiBundle/Controller/EntryRestController.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Wallabag/ApiBundle/Controller/EntryRestController.php b/src/Wallabag/ApiBundle/Controller/EntryRestController.php
index dbff6065..632b16d9 100644
--- a/src/Wallabag/ApiBundle/Controller/EntryRestController.php
+++ b/src/Wallabag/ApiBundle/Controller/EntryRestController.php
@@ -95,12 +95,13 @@ class EntryRestController extends WallabagRestController
95 $tags = $request->query->get('tags', ''); 95 $tags = $request->query->get('tags', '');
96 $since = $request->query->get('since', 0); 96 $since = $request->query->get('since', 0);
97 97
98 /** @var \Pagerfanta\Pagerfanta $pager */
98 $pager = $this->getDoctrine() 99 $pager = $this->getDoctrine()
99 ->getRepository('WallabagCoreBundle:Entry') 100 ->getRepository('WallabagCoreBundle:Entry')
100 ->findEntries($this->getUser()->getId(), $isArchived, $isStarred, $sort, $order, $since, $tags); 101 ->findEntries($this->getUser()->getId(), $isArchived, $isStarred, $sort, $order, $since, $tags);
101 102
102 $pager->setCurrentPage($page);
103 $pager->setMaxPerPage($perPage); 103 $pager->setMaxPerPage($perPage);
104 $pager->setCurrentPage($page);
104 105
105 $pagerfantaFactory = new PagerfantaFactory('page', 'perPage'); 106 $pagerfantaFactory = new PagerfantaFactory('page', 'perPage');
106 $paginatedCollection = $pagerfantaFactory->createRepresentation( 107 $paginatedCollection = $pagerfantaFactory->createRepresentation(