From 1d5410c712a3cf152c54c597c50894e482bcd0f2 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Tue, 17 Oct 2006 13:20:35 +0000 Subject: Bug 350921: [email_in] Create an email interface that can create a bug in Bugzilla Patch By Max Kanat-Alexander r=colin, r=ghendricks, a=myk --- post_bug.cgi | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'post_bug.cgi') diff --git a/post_bug.cgi b/post_bug.cgi index 74da0fd00..59c079897 100755 --- a/post_bug.cgi +++ b/post_bug.cgi @@ -29,6 +29,7 @@ use lib qw(.); use Bugzilla; use Bugzilla::Attachment; +use Bugzilla::BugMail; use Bugzilla::Constants; use Bugzilla::Util; use Bugzilla::Error; @@ -243,8 +244,13 @@ if ($token) { ("createbug:$id", $token)); } -print $cgi->header(); -$template->process("bug/create/created.html.tmpl", $vars) - || ThrowTemplateError($template->error()); - +if (Bugzilla->usage_mode == USAGE_MODE_EMAIL) { + Bugzilla::BugMail::Send($id, $vars->{'mailrecipients'}); +} +else { + print $cgi->header(); + $template->process("bug/create/created.html.tmpl", $vars) + || ThrowTemplateError($template->error()); +} +1; -- cgit v1.2.3-24-g4f1b