diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2020-09-11 15:16:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-11 15:16:29 +0200 |
commit | e6b272e5c9c227cfbbe375a893f567c5967d669c (patch) | |
tree | 83aa2fe629cc54225531852fe7020388277ba040 /app/controllers/api/v1/lists/accounts_controller.rb | |
parent | e6d67f85e288a5c3137c9fc09f99c9051544d87c (diff) |
Change REST API to return empty data for suspended accounts (#14765)
Diffstat (limited to 'app/controllers/api/v1/lists/accounts_controller.rb')
-rw-r--r-- | app/controllers/api/v1/lists/accounts_controller.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/controllers/api/v1/lists/accounts_controller.rb b/app/controllers/api/v1/lists/accounts_controller.rb index 23078263e..b66ea9bfe 100644 --- a/app/controllers/api/v1/lists/accounts_controller.rb +++ b/app/controllers/api/v1/lists/accounts_controller.rb @@ -37,9 +37,9 @@ class Api::V1::Lists::AccountsController < Api::BaseController def load_accounts if unlimited? - @list.accounts.includes(:account_stat).all + @list.accounts.without_suspended.includes(:account_stat).all else - @list.accounts.includes(:account_stat).paginate_by_max_id(limit_param(DEFAULT_ACCOUNTS_LIMIT), params[:max_id], params[:since_id]) + @list.accounts.without_suspended.includes(:account_stat).paginate_by_max_id(limit_param(DEFAULT_ACCOUNTS_LIMIT), params[:max_id], params[:since_id]) end end |