From a3909514bf2574dd44b969dfcb69d51a438cd7ac Mon Sep 17 00:00:00 2001 From: Eugen Rochko Date: Thu, 26 May 2022 18:54:29 +0200 Subject: [PATCH] Fix being able to report otherwise inaccessible statuses --- app/controllers/api/v1/reports_controller.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/controllers/api/v1/reports_controller.rb b/app/controllers/api/v1/reports_controller.rb index e10083d45..89241d362 100644 --- a/app/controllers/api/v1/reports_controller.rb +++ b/app/controllers/api/v1/reports_controller.rb @@ -21,7 +21,7 @@ class Api::V1::ReportsController < Api::BaseController private def reported_status_ids - reported_account.statuses.with_discarded.find(status_ids).pluck(:id) + reported_account.statuses.with_discarded.permitted_for(reported_account, current_account).find(status_ids).pluck(:id) end def status_ids