diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-03-22 21:38:47 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-03-22 21:38:47 +0100 |
commit | 12559b01eae408c0f3e820ef9c6bc6e356ab889a (patch) | |
tree | 87d857393ce24b1937c654ce7252b6315b7e77f9 /app/controllers/api/accounts_controller.rb | |
parent | 02e4fb2e06f424c16ab25ea294a4af6490a5f7e3 (diff) |
Add pagination by max_id instead of offset/limit
Diffstat (limited to 'app/controllers/api/accounts_controller.rb')
-rw-r--r-- | app/controllers/api/accounts_controller.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/controllers/api/accounts_controller.rb b/app/controllers/api/accounts_controller.rb index f543ea98d..5bac98f81 100644 --- a/app/controllers/api/accounts_controller.rb +++ b/app/controllers/api/accounts_controller.rb @@ -15,7 +15,7 @@ class Api::AccountsController < ApiController end def statuses - @statuses = @account.statuses.with_includes.with_counters.order('created_at desc') + @statuses = @account.statuses.with_includes.with_counters.paginate_by_max_id(20, params[:max_id]) end def follow |