Refactor controllers for statuses, accounts, and more (#11249)
This commit is contained in:
parent
f14776475d
commit
63c7fe8e48
41 changed files with 299 additions and 289 deletions
|
@ -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
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue