diff options
author | Phil Hughes <me@iamphill.com> | 2016-03-03 17:04:32 +0000 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2016-03-10 08:39:47 +0000 |
commit | 12506abfe794e75fcaa879b92bee09b8da57bf46 (patch) | |
tree | 9ed8851a9eee81d133d039cd895e1ddc592b44c5 | |
parent | 538f3e0d716d0f8c107af030fb318808f9e284ac (diff) | |
download | gitlab-ce-12506abfe794e75fcaa879b92bee09b8da57bf46.tar.gz |
Single if statement
-rw-r--r-- | app/helpers/application_helper.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index f99a14c0e01..212fecc3e77 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -196,11 +196,9 @@ module ApplicationHelper output = content_tag(:span, "Edited ") output << time_ago_with_tooltip(object.updated_at, placement: placement, html_class: html_class) - if include_author - if object.updated_by && object.updated_by != object.author - output << content_tag(:span, " by ") - output << link_to_member(object.project, object.updated_by, avatar: false, author_class: nil) - end + if include_author && object.updated_by && object.updated_by != object.author + output << content_tag(:span, " by ") + output << link_to_member(object.project, object.updated_by, avatar: false, author_class: nil) end output |