From: Hypolite Petovan Date: Wed, 24 Oct 2018 15:50:37 +0000 (-0400) Subject: Update Pager->__construct calls for minimal use cases X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=74e80f137bafb1b2f750f600a80f2901f8a29f99;p=friendica.git Update Pager->__construct calls for minimal use cases --- diff --git a/mod/community.php b/mod/community.php index 7474fc2429..1017698eaa 100644 --- a/mod/community.php +++ b/mod/community.php @@ -154,7 +154,7 @@ function community_content(App $a, $update = 0) $itemspage_network = $a->force_max_items; } - $pager = new Pager($a->query_string, null, $itemspage_network); + $pager = new Pager($a->query_string, $itemspage_network); $r = community_getitems($pager->getStart(), $pager->getItemsPerPage(), $content, $accounttype); diff --git a/mod/notes.php b/mod/notes.php index b6b6faefab..01e6e5ab99 100644 --- a/mod/notes.php +++ b/mod/notes.php @@ -61,7 +61,7 @@ function notes_content(App $a, $update = false) $condition = ['uid' => local_user(), 'post-type' => Item::PT_PERSONAL_NOTE, 'gravity' => GRAVITY_PARENT, 'wall' => false, 'contact-id'=> $a->contact['id']]; - $pager = new Pager($a->query_string, null, 40); + $pager = new Pager($a->query_string, 40); $params = ['order' => ['created' => true], 'limit' => [$pager->getStart(), $pager->getItemsPerPage()]]; diff --git a/mod/notifications.php b/mod/notifications.php index 748af40d5d..81084c1bc3 100644 --- a/mod/notifications.php +++ b/mod/notifications.php @@ -121,7 +121,7 @@ function notifications_content(App $a) } // Set the pager - $pager = new Pager($a->query_string, null, $perpage); + $pager = new Pager($a->query_string, $perpage); // Add additional informations (needed for json output) $notifs['items_page'] = $pager->getItemsPerPage(); diff --git a/mod/profile.php b/mod/profile.php index 2cea4eedf4..d068fca47b 100644 --- a/mod/profile.php +++ b/mod/profile.php @@ -308,7 +308,7 @@ function profile_content(App $a, $update = 0) $itemspage_network = $a->force_max_items; } - $pager = new Pager($a->query_string, null, $itemspage_network); + $pager = new Pager($a->query_string, $itemspage_network); $pager_sql = sprintf(" LIMIT %d, %d ", $pager->getStart(), $pager->getItemsPerPage());