From 0eeac4a669e46fb6521ae1765b23656c9afc43de Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Sun, 21 Jul 2024 14:54:34 +0200 Subject: Revisit keepMaxUnreads (#6632) * Revisit keepMaxUnreads Again, follow-up of https://github.com/FreshRSS/FreshRSS/pull/5905 fix https://github.com/FreshRSS/FreshRSS/issues/6620 * Refactoring to address buggy cases * Fix minor test --- p/api/greader.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'p/api/greader.php') diff --git a/p/api/greader.php b/p/api/greader.php index 71cf40884..9c3479546 100644 --- a/p/api/greader.php +++ b/p/api/greader.php @@ -331,10 +331,7 @@ final class GReaderAPI { $importService = new FreshRSS_Import_Service($user); $importService->importOpml($opml); if ($importService->lastStatus()) { - [, , $nb_new_articles] = FreshRSS_feed_Controller::actualizeFeeds(); - if ($nb_new_articles > 0) { - FreshRSS_feed_Controller::commitNewEntries(); - } + FreshRSS_feed_Controller::actualizeFeedsAndCommit(); invalidateHttpCache($user); exit('OK'); } else { -- cgit v1.2.3