diff options
Diffstat (limited to 'app/finders/security/jobs_finder.rb')
-rw-r--r-- | app/finders/security/jobs_finder.rb | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/app/finders/security/jobs_finder.rb b/app/finders/security/jobs_finder.rb index 99bcf97f43c..6c2090e0509 100644 --- a/app/finders/security/jobs_finder.rb +++ b/app/finders/security/jobs_finder.rb @@ -38,11 +38,7 @@ module Security def execute return [] if @job_types.empty? - if Feature.enabled?(:ci_build_metadata_config, pipeline.project, default_enabled: :yaml) - find_jobs - else - find_jobs_legacy - end + find_jobs end private @@ -51,19 +47,6 @@ module Security @pipeline.builds.with_secure_reports_from_config_options(@job_types) end - def find_jobs_legacy - # the query doesn't guarantee accuracy, so we verify it here - legacy_jobs_query.select do |job| - @job_types.find { |job_type| job.options.dig(:artifacts, :reports, job_type) } - end - end - - def legacy_jobs_query - @job_types.map do |job_type| - @pipeline.builds.with_secure_reports_from_options(job_type) - end.reduce(&:or) - end - def valid_job_types?(job_types) (job_types - self.class.allowed_job_types).empty? end |