]> git.mxchange.org Git - friendica.git/commitdiff
Fix offset is absolute in set not a page to be consistent with SQL
authorHank Grabowski <hankgrabowski@gmail.com>
Fri, 17 Feb 2023 18:23:34 +0000 (13:23 -0500)
committerHank Grabowski <hankgrabowski@gmail.com>
Fri, 17 Feb 2023 18:23:34 +0000 (13:23 -0500)
src/Model/Tag.php

index 362df49ec763e46a1d83256ac71b2eb39b68081e..0e891f9c6f27870e314aa75a7b8e74329f3e94ff 100644 (file)
@@ -652,7 +652,7 @@ class Tag
                if (empty($tags)) {
                        $tags = self::setGlobalTrendingHashtags($period, 1000);
                }
-               return array_slice($tags, $limit * $offset, $limit);
+               return array_slice($tags, $offset, $limit);
        }
 
        /**
@@ -735,7 +735,7 @@ class Tag
                if (empty($tags)) {
                        $tags = self::setLocalTrendingHashtags($period, 1000);
                }
-               return array_slice($tags, $limit * $offset, $limit);
+               return array_slice($tags, $offset, $limit);
        }
 
        /**