Skip to content

Move `authorize_read_build_trace!` method to `Ci::AuthBuildTrace`

What does this MR do and why?

This MR moves the authorize_read_build_trace! method from Projects::ApplicationController to a new method in Ci::AuthBuildTrace, from #387676 (closed):

We currently have authorize_read_build_trace! in the Projects::ApplicationController that provides a more specific error message if debug_mode is enabled. This code isn't scoped to the domain.

This code should be moved out of the Projects::ApplicationController to somewhere more specific to the CI domain. Currently it is there because it needs to be shared with the artifacts and jobs controllers but ends up callable from all project related controllers when it's only relevant in those two.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #387676 (closed)

Merge request reports