From: Albert Ting Date: Sat, 2 Jan 2016 21:29:01 +0000 (-0500) Subject: Bug 1202853 - Markdown doesn't work when adding a comment attachment X-Git-Tag: release-5.1.1~116 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9f5a8a28783f66b15973ac3714d10d1c0fa05f6d;p=thirdparty%2Fbugzilla.git Bug 1202853 - Markdown doesn't work when adding a comment attachment r=dylan,a=dylan --- diff --git a/attachment.cgi b/attachment.cgi index e7fadf66f0..ae9efef6aa 100755 --- a/attachment.cgi +++ b/attachment.cgi @@ -548,9 +548,12 @@ sub insert { # Insert a comment about the new attachment into the database. my $comment = $cgi->param('comment'); $comment = '' unless defined $comment; + my $is_markdown = ($user->use_markdown + && $cgi->param('use_markdown')) ? 1 : 0; $bug->add_comment($comment, { isprivate => $attachment->isprivate, type => CMT_ATTACHMENT_CREATED, - extra_data => $attachment->id }); + extra_data => $attachment->id, + is_markdown => $is_markdown}); # Assign the bug to the user, if they are allowed to take it my $owner = "";