2
0

Simplify instance presenter view access (#26046)

This commit is contained in:
Matt Jankowski
2023-09-28 10:52:37 -04:00
committed by GitHub
parent 2016c5d912
commit 340f1a68be
11 changed files with 5 additions and 58 deletions

View File

@@ -10,7 +10,6 @@ class StatusesController < ApplicationController
before_action :require_account_signature!, only: [:show, :activity], if: -> { request.format == :json && authorized_fetch_mode? }
before_action :set_status
before_action :set_instance_presenter
before_action :redirect_to_original, only: :show
before_action :set_body_classes, only: :embed
@@ -67,10 +66,6 @@ class StatusesController < ApplicationController
not_found
end
def set_instance_presenter
@instance_presenter = InstancePresenter.new
end
def redirect_to_original
redirect_to(ActivityPub::TagManager.instance.url_for(@status.reblog), allow_other_host: true) if @status.reblog?
end