about summary refs log tree commit diff
path: root/app/controllers/api/v1/accounts_controller.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2020-09-11 15:16:29 +0200
committerGitHub <noreply@github.com>2020-09-11 15:16:29 +0200
commite6b272e5c9c227cfbbe375a893f567c5967d669c (patch)
tree83aa2fe629cc54225531852fe7020388277ba040 /app/controllers/api/v1/accounts_controller.rb
parente6d67f85e288a5c3137c9fc09f99c9051544d87c (diff)
Change REST API to return empty data for suspended accounts (#14765)
Diffstat (limited to 'app/controllers/api/v1/accounts_controller.rb')
-rw-r--r--app/controllers/api/v1/accounts_controller.rb5
1 files changed, 0 insertions, 5 deletions
diff --git a/app/controllers/api/v1/accounts_controller.rb b/app/controllers/api/v1/accounts_controller.rb
index 0080faf33..61dcb87c2 100644
--- a/app/controllers/api/v1/accounts_controller.rb
+++ b/app/controllers/api/v1/accounts_controller.rb
@@ -9,7 +9,6 @@ class Api::V1::AccountsController < Api::BaseController
 
   before_action :require_user!, except: [:show, :create]
   before_action :set_account, except: [:create]
-  before_action :check_account_suspension, only: [:show]
   before_action :check_enabled_registrations, only: [:create]
 
   skip_before_action :require_authenticated_user!, only: :create
@@ -73,10 +72,6 @@ class Api::V1::AccountsController < Api::BaseController
     AccountRelationshipsPresenter.new([@account.id], current_user.account_id, options)
   end
 
-  def check_account_suspension
-    gone if @account.suspended?
-  end
-
   def account_params
     params.permit(:username, :email, :password, :agreement, :locale, :reason)
   end