You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

15 lines
318 B

  1. # frozen_string_literal: true
  2. class FollowingAccountsController < ApplicationController
  3. include AccountControllerConcern
  4. def index
  5. @accounts = ordered_accounts.page(params[:page]).per(FOLLOW_PER_PAGE)
  6. end
  7. private
  8. def ordered_accounts
  9. @account.following.order('follows.created_at desc')
  10. end
  11. end