From 94da0fcd4a7bf7b9d9dfeef9cadb5c57349ab80d Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Sat, 29 Jun 2019 20:47:38 +0200 Subject: [PATCH] Fix wrong mark-as-read maxId argument (#2431) Fix https://github.com/FreshRSS/FreshRSS/issues/2429 --- app/Controllers/indexController.php | 2 +- app/layout/nav_menu.phtml | 9 ++++++++- app/views/index/global.phtml | 5 ----- app/views/index/normal.phtml | 5 ----- app/views/index/reader.phtml | 5 ----- 5 files changed, 9 insertions(+), 17 deletions(-) diff --git a/app/Controllers/indexController.php b/app/Controllers/indexController.php index 824d658155d9..f536113dd007 100755 --- a/app/Controllers/indexController.php +++ b/app/Controllers/indexController.php @@ -54,7 +54,7 @@ public function normalAction() { } }; - $this->view->callbackBeforeEntries = function ($view) { + $this->view->callbackBeforePagination = function ($view) { try { FreshRSS_Context::$number++; //+1 for pagination $entries = FreshRSS_index_Controller::listEntriesByContext(); diff --git a/app/layout/nav_menu.phtml b/app/layout/nav_menu.phtml index 4d860a54c329..af7267bacb24 100644 --- a/app/layout/nav_menu.phtml +++ b/app/layout/nav_menu.phtml @@ -1,4 +1,11 @@ - +callbackBeforePagination)) { + call_user_func($this->callbackBeforePagination, $this); + } +?>