From dbcb78e9b4e5620b69ba50f167aeab254767b3b0 Mon Sep 17 00:00:00 2001
From: Kevin Ditscheid <kevinditscheid@gmail.com>
Date: Fri, 13 Apr 2018 10:34:53 +0200
Subject: [PATCH] [BUGFIX] Remove wrongly applied substraction from offset

---
 Classes/Controller/LatestController.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Classes/Controller/LatestController.php b/Classes/Controller/LatestController.php
index 03a95c5..d08977f 100644
--- a/Classes/Controller/LatestController.php
+++ b/Classes/Controller/LatestController.php
@@ -100,7 +100,7 @@ class LatestController extends AbstractController {
 
 		// Redo this function, until $newsMetaData gets the $limit. Needed because of languagevisibility.
 		if (count($newsMetaData) < $limit) {
-			$offset += $limit - 1;
+			$offset += $limit;
 			$maxCount = $this->newsRepository->getCountOfLastUpdatedOrHighlightedNewsByCategories(
 				FALSE, $categoryUids, TRUE, $this->settings['sortBy'], $tagUids, $startTime, $endTime
 			);
-- 
GitLab