Commit e358ae16 authored by Matija Čupić's avatar Matija Čupić

Inline initialize_yaml_processor

parent 7600a646
...@@ -464,7 +464,7 @@ module Ci ...@@ -464,7 +464,7 @@ module Ci
return @config_processor if defined?(@config_processor) return @config_processor if defined?(@config_processor)
@config_processor ||= begin @config_processor ||= begin
initialize_yaml_processor ::Gitlab::Ci::YamlProcessor.new(ci_yaml_file, { project: project, sha: sha })
rescue Gitlab::Ci::YamlProcessor::ValidationError => e rescue Gitlab::Ci::YamlProcessor::ValidationError => e
self.yaml_errors = e.message self.yaml_errors = e.message
nil nil
...@@ -474,10 +474,6 @@ module Ci ...@@ -474,10 +474,6 @@ module Ci
end end
end end
def initialize_yaml_processor
::Gitlab::Ci::YamlProcessor.new(ci_yaml_file, { project: project, sha: sha })
end
def ci_yaml_file_path def ci_yaml_file_path
if project.ci_config_path.blank? if project.ci_config_path.blank?
'.gitlab-ci.yml' '.gitlab-ci.yml'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment