summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-08-02 15:12:07 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-08-02 15:12:07 +0300
commit14e88565c68de056c83ddc53a68ade4c3f82b531 (patch)
tree82cb417884043292e5cf81c516debcaf5b9ba4cd
parent8cd80da8bb5c4f67b08cb2334472fac54d083ab3 (diff)
downloadgitlab-ce-14e88565c68de056c83ddc53a68ade4c3f82b531.tar.gz
Refactor pipline info box view
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
-rw-r--r--app/views/projects/pipelines/_info.html.haml4
-rw-r--r--app/views/projects/pipelines/show.html.haml4
2 files changed, 2 insertions, 6 deletions
diff --git a/app/views/projects/pipelines/_info.html.haml b/app/views/projects/pipelines/_info.html.haml
index cdbef98df29..78e3b209686 100644
--- a/app/views/projects/pipelines/_info.html.haml
+++ b/app/views/projects/pipelines/_info.html.haml
@@ -1,7 +1,3 @@
-- commit = local_assigns.fetch(:commit)
-
-- return unless commit&.present?
-
.commit-box
%h3.commit-title
= markdown(commit.title, pipeline: :single_line)
diff --git a/app/views/projects/pipelines/show.html.haml b/app/views/projects/pipelines/show.html.haml
index 4066e2c590d..ff0ed3ed30d 100644
--- a/app/views/projects/pipelines/show.html.haml
+++ b/app/views/projects/pipelines/show.html.haml
@@ -4,10 +4,10 @@
- page_title "Pipeline"
.js-pipeline-container{ class: container_class, data: { controller_action: "#{controller.action_name}" } }
-
#js-pipeline-header-vue.pipeline-header-container
- = render "projects/pipelines/info", commit: @pipeline.commit
+ - if @pipeline.commit.present?
+ = render "projects/pipelines/info", commit: @pipeline.commit
= render "projects/pipelines/with_tabs", pipeline: @pipeline