Patch by Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=LpSolit
if ($deptext) {
my $diffpart = {};
- $diffpart->{'text'} = "\n" . trim("\n\n" . $deptext);
+ $diffpart->{'text'} = "\n" . trim($deptext);
push(@diffparts, $diffpart);
}
}
}
my $diffs = $difftext;
+ # Remove extra newlines.
+ $diffs =~ s/^\n+//s; $diffs =~ s/\n+$//s;
if ($isnew) {
my $head = "";
foreach my $f (@headerlist) {
[%+ threadingmarker %]
[%+ urlbase %]show_bug.cgi?id=[% bugid %]
+[%- IF diffs %]
[%+ diffs %]
+[% END -%]
[% FOREACH comment = new_comments %]
--- Comment #[% comment.count %] from [% comment.author.identity %] [%+ comment.time FILTER time %] ---