diff --git a/app/views/projects/builds/_sidebar.html.haml b/app/views/projects/builds/_sidebar.html.haml
index 3fc1157ddcb04c61c9a6ef3f9d2e47f6c21ceb8e..aba09a37ac75089823d022a7b47505ecb4d2fd97 100644
--- a/app/views/projects/builds/_sidebar.html.haml
+++ b/app/views/projects/builds/_sidebar.html.haml
@@ -96,7 +96,7 @@
     .title
       Commit title
     %p.build-light-text.append-bottom-0
-      #{@build.pipeline.commit.try(:title)}
+      #{@build.commit.title}
 
   - if @build.tags.any?
     .block