Commit 36aea928 authored by Mike Greiling's avatar Mike Greiling

invert if statement order

parent 5c36905a
...@@ -121,12 +121,12 @@ ...@@ -121,12 +121,12 @@
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;padding-right:5px;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;padding-right:5px;"}
%img.avatar{height: "24", src: avatar_icon(commit.author || commit.author_email, 24), style: "display:block;border-radius:12px;margin:-2px 0;", width: "24"}/ %img.avatar{height: "24", src: avatar_icon(commit.author || commit.author_email, 24), style: "display:block;border-radius:12px;margin:-2px 0;", width: "24"}/
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;"}
- if commit.author.nil? - if commit.author
%span
= commit.author_name
- else
%a.muted{href: user_url(commit.author), style: "color:#333333;text-decoration:none;"} %a.muted{href: user_url(commit.author), style: "color:#333333;text-decoration:none;"}
= commit.author.name = commit.author.name
- else
%span
= commit.author_name
%tr.spacer %tr.spacer
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;height:18px;font-size:18px;line-height:18px;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;height:18px;font-size:18px;line-height:18px;"}
   
......
...@@ -9,10 +9,10 @@ Merge Request: <%= @merge_request.to_reference %> ( <%= merge_request_url(@merge ...@@ -9,10 +9,10 @@ Merge Request: <%= @merge_request.to_reference %> ( <%= merge_request_url(@merge
Commit: <%= @pipeline.short_sha %> ( <%= namespace_project_commit_url(@project.namespace, @project, @pipeline.sha) %> ) Commit: <%= @pipeline.short_sha %> ( <%= namespace_project_commit_url(@project.namespace, @project, @pipeline.sha) %> )
Commit Message: <%= @pipeline.git_commit_message.truncate(50) %> Commit Message: <%= @pipeline.git_commit_message.truncate(50) %>
<% commit = @pipeline.commit -%> <% commit = @pipeline.commit -%>
<% if commit.author.nil? -%> <% if commit.author -%>
Commit Author: <%= commit.author_name %>
<% else -%>
Commit Author: <%= commit.author.name %> ( <%= user_url(commit.author) %> ) Commit Author: <%= commit.author.name %> ( <%= user_url(commit.author) %> )
<% else -%>
Commit Author: <%= commit.author_name %>
<% end -%> <% end -%>
<% failed = @pipeline.statuses.latest.failed -%> <% failed = @pipeline.statuses.latest.failed -%>
......
...@@ -121,12 +121,12 @@ ...@@ -121,12 +121,12 @@
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;padding-right:5px;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;padding-right:5px;"}
%img.avatar{height: "24", src: avatar_icon(commit.author || commit.author_email, 24), style: "display:block;border-radius:12px;margin:-2px 0;", width: "24"}/ %img.avatar{height: "24", src: avatar_icon(commit.author || commit.author_email, 24), style: "display:block;border-radius:12px;margin:-2px 0;", width: "24"}/
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;font-size:15px;line-height:1.4;vertical-align:middle;"}
- if commit.author.nil? - if commit.author
%span
= commit.author_name
- else
%a.muted{href: user_url(commit.author), style: "color:#333333;text-decoration:none;"} %a.muted{href: user_url(commit.author), style: "color:#333333;text-decoration:none;"}
= commit.author.name = commit.author.name
- else
%span
= commit.author_name
%tr.spacer %tr.spacer
%td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;height:18px;font-size:18px;line-height:18px;"} %td{style: "font-family:'Helvetica Neue',Helvetica,Arial,sans-serif;height:18px;font-size:18px;line-height:18px;"}
&nbsp; &nbsp;
......
...@@ -9,10 +9,10 @@ Merge Request: <%= @merge_request.to_reference %> ( <%= merge_request_url(@merge ...@@ -9,10 +9,10 @@ Merge Request: <%= @merge_request.to_reference %> ( <%= merge_request_url(@merge
Commit: <%= @pipeline.short_sha %> ( <%= namespace_project_commit_url(@project.namespace, @project, @pipeline.sha) %> ) Commit: <%= @pipeline.short_sha %> ( <%= namespace_project_commit_url(@project.namespace, @project, @pipeline.sha) %> )
Commit Message: <%= @pipeline.git_commit_message.truncate(50) %> Commit Message: <%= @pipeline.git_commit_message.truncate(50) %>
<% commit = @pipeline.commit -%> <% commit = @pipeline.commit -%>
<% if commit.author.nil? -%> <% if commit.author -%>
Commit Author: <%= commit.author_name %>
<% else -%>
Commit Author: <%= commit.author.name %> ( <%= user_url(commit.author) %> ) Commit Author: <%= commit.author.name %> ( <%= user_url(commit.author) %> )
<% else -%>
Commit Author: <%= commit.author_name %>
<% end -%> <% end -%>
<% build_count = @pipeline.statuses.latest.size -%> <% build_count = @pipeline.statuses.latest.size -%>
......
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