about summary refs log tree commit diff
path: root/app/controllers/remote_follow_controller.rb
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2019-07-08 12:03:45 +0200
committerGitHub <noreply@github.com>2019-07-08 12:03:45 +0200
commit63c7fe8e4892b22e80c015bf0ecb04496318623b (patch)
treec724cb6e1006dbd1d5cccd3719d096ff62124644 /app/controllers/remote_follow_controller.rb
parentf14776475d285bb7d2831a20192c1611c733f410 (diff)
Refactor controllers for statuses, accounts, and more (#11249)
Diffstat (limited to 'app/controllers/remote_follow_controller.rb')
-rw-r--r--app/controllers/remote_follow_controller.rb12
1 files changed, 2 insertions, 10 deletions
diff --git a/app/controllers/remote_follow_controller.rb b/app/controllers/remote_follow_controller.rb
index 8ba331cd1..0fb71d335 100644
--- a/app/controllers/remote_follow_controller.rb
+++ b/app/controllers/remote_follow_controller.rb
@@ -1,10 +1,10 @@
 # frozen_string_literal: true
 
 class RemoteFollowController < ApplicationController
+  include AccountOwnedConcern
+
   layout 'modal'
 
-  before_action :set_account
-  before_action :gone, if: :suspended_account?
   before_action :set_body_classes
 
   def new
@@ -32,14 +32,6 @@ class RemoteFollowController < ApplicationController
     { acct: session[:remote_follow] }
   end
 
-  def set_account
-    @account = Account.find_local!(params[:account_username])
-  end
-
-  def suspended_account?
-    @account.suspended?
-  end
-
   def set_body_classes
     @body_classes = 'modal-layout'
     @hide_header  = true