From: db48x%yahoo.com <> Date: Tue, 27 Feb 2007 04:05:22 +0000 (+0000) Subject: bug 369429: bug reports should contain microformat markup in order to make the inform... X-Git-Tag: bugzilla-3.1.2~326 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=41732933eeb2f25abdd479e5a024cd258c502fd3;p=thirdparty%2Fbugzilla.git bug 369429: bug reports should contain microformat markup in order to make the information in them more useable. r=LpSolit --- diff --git a/Bugzilla/Bug.pm b/Bugzilla/Bug.pm index 8591a2f890..8ee0d87e27 100755 --- a/Bugzilla/Bug.pm +++ b/Bugzilla/Bug.pm @@ -1475,7 +1475,6 @@ sub GetComments { my %comment = %$comment_ref; $comment{'email'} .= Bugzilla->params->{'emailsuffix'}; - $comment{'name'} = $comment{'name'} || $comment{'email'}; # If raw data is requested, do not format 'special' comments. $comment{'body'} = format_comment(\%comment) unless $raw; diff --git a/Bugzilla/BugMail.pm b/Bugzilla/BugMail.pm index fa52464f83..79033dbbe3 100644 --- a/Bugzilla/BugMail.pm +++ b/Bugzilla/BugMail.pm @@ -704,11 +704,11 @@ sub prepare_comments { foreach my $comment (@$raw_comments) { if ($count) { $result .= "\n\n--- Comment #$count from "; - if ($comment->{'name'} eq $comment->{'email'}) { - $result .= $comment->{'email'} . Bugzilla->params->{'emailsuffix'}; - } else { + if ($comment->{'name'}) { $result .= $comment->{'name'} . " <" . $comment->{'email'} . Bugzilla->params->{'emailsuffix'} . ">"; + } else { + $result .= $comment->{'email'} . Bugzilla->params->{'emailsuffix'}; } $result .= " " . format_time($comment->{'time'}) . " ---\n"; } diff --git a/template/en/default/bug/comments.html.tmpl b/template/en/default/bug/comments.html.tmpl index 5add6d54f4..9d05ba4ace 100644 --- a/template/en/default/bug/comments.html.tmpl +++ b/template/en/default/bug/comments.html.tmpl @@ -113,8 +113,11 @@ ------- Comment #[% count %] From - - [% comment.name FILTER html %] + + + [% (comment.name || comment.email) FILTER html %] + + [%+ comment.time FILTER time %] [% IF mode == "edit" %] diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl index 5389af666a..c97077d699 100644 --- a/template/en/default/bug/edit.html.tmpl +++ b/template/en/default/bug/edit.html.tmpl @@ -673,8 +673,7 @@ Reporter: