From 7719cc21043e5aa8a77b64b682362c4cf5a8a1f5 Mon Sep 17 00:00:00 2001 From: Toks Date: Mon, 24 Jun 2013 11:17:43 -0400 Subject: [PATCH] don't show comment updated by if the edit occurred within 5 minutes --- app/views/comments/partials/show/_comment.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/comments/partials/show/_comment.html.erb b/app/views/comments/partials/show/_comment.html.erb index 3662a7a98..a72285e99 100644 --- a/app/views/comments/partials/show/_comment.html.erb +++ b/app/views/comments/partials/show/_comment.html.erb @@ -9,7 +9,7 @@
<%= format_text(comment.body) %> - <% if comment.updater_id.present? && (comment.updater_id != comment.creator_id || comment.created_at != comment.updated_at) %> + <% if comment.updated_at - comment.created_at > 5.minutes %>

Updated by <%= link_to_user comment.updater %> <%= time_ago_in_words_tagged(comment.updated_at) %>

<% end %>