Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app/presenters/ml/candidate_details_presenter.rb')
-rw-r--r--app/presenters/ml/candidate_details_presenter.rb7
1 files changed, 4 insertions, 3 deletions
diff --git a/app/presenters/ml/candidate_details_presenter.rb b/app/presenters/ml/candidate_details_presenter.rb
index 7f0bd9d6c11..29d4617903f 100644
--- a/app/presenters/ml/candidate_details_presenter.rb
+++ b/app/presenters/ml/candidate_details_presenter.rb
@@ -4,8 +4,9 @@ module Ml
class CandidateDetailsPresenter
include Rails.application.routes.url_helpers
- def initialize(candidate)
+ def initialize(candidate, include_ci_job = false)
@candidate = candidate
+ @include_ci_job = include_ci_job
end
def present
@@ -32,10 +33,10 @@ module Ml
private
- attr_reader :candidate
+ attr_reader :candidate, :include_ci_job
def job_info
- return unless candidate.from_ci?
+ return unless include_ci_job && candidate.from_ci?
build = candidate.ci_build