From 2addcaadedfe714bd0502911cc85cdab24736465 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Buclin?= Date: Sun, 18 Jul 2010 19:17:26 +0200 Subject: Bug 119703: Create an attachment by pasting it into a text field r/a=mkanat --- attachment.cgi | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'attachment.cgi') diff --git a/attachment.cgi b/attachment.cgi index ca82bc463..5bb2a8537 100755 --- a/attachment.cgi +++ b/attachment.cgi @@ -478,12 +478,11 @@ sub insert { my $attachment = Bugzilla::Attachment->create( {bug => $bug, creation_ts => $timestamp, - data => scalar $cgi->param('attachurl') || $cgi->upload('data'), + data => scalar $cgi->param('attach_text') || $cgi->upload('data'), description => scalar $cgi->param('description'), - filename => $cgi->param('attachurl') ? '' : scalar $cgi->upload('data'), + filename => $cgi->param('attach_text') ? 'attachment.txt' : scalar $cgi->upload('data'), ispatch => scalar $cgi->param('ispatch'), isprivate => scalar $cgi->param('isprivate'), - isurl => scalar $cgi->param('attachurl'), mimetype => $content_type, }); -- cgit v1.2.1