]> cat aescling's git repositories - mastodon.git/commitdiff
Fix `GET /api/v1/trends/tags` missing `offset` param in REST API (#17973)
authorEugen Rochko <eugen@zeonfederated.com>
Wed, 6 Apr 2022 18:56:57 +0000 (20:56 +0200)
committerGitHub <noreply@github.com>
Wed, 6 Apr 2022 18:56:57 +0000 (20:56 +0200)
app/controllers/api/v1/trends/tags_controller.rb

index d77857871acbc28e1e3f9bae46f92528cb0dd1be..329ef5ae73c5db4c483195787b5281af14e1c0f2 100644 (file)
@@ -16,7 +16,7 @@ class Api::V1::Trends::TagsController < Api::BaseController
   def set_tags
     @tags = begin
       if Setting.trends
-        Trends.tags.query.allowed.limit(limit_param(DEFAULT_TAGS_LIMIT))
+        Trends.tags.query.allowed.offset(offset_param).limit(limit_param(DEFAULT_TAGS_LIMIT))
       else
         []
       end