diff --git a/mozilla/webtools/bugzilla/Bugzilla/BugMail.pm b/mozilla/webtools/bugzilla/Bugzilla/BugMail.pm index a0c11ef2047..1221dcfbc4c 100644 --- a/mozilla/webtools/bugzilla/Bugzilla/BugMail.pm +++ b/mozilla/webtools/bugzilla/Bugzilla/BugMail.pm @@ -883,17 +883,17 @@ sub NewProcessOnePerson ($$$$$$$$$$$$$) { sub MessageToMTA ($) { my ($msg) = (@_); - return unless Param('enable_mail_sending'); + return if (Param('mail_delivery_method') eq "none"); my @args; - if (Param("maildeliverymethod") eq "sendmail" && !Param("sendmailnow")) { + if (Param("mail_delivery_method") eq "sendmail" && !Param("sendmailnow")) { push @args, "-ODeliveryMode=deferred"; } - if (Param("maildeliverymethod") eq "smtp") { + if (Param("mail_delivery_method") eq "smtp") { push @args, Server => Param("smtpserver"); } - my $mailer = new Mail::Mailer Param("maildeliverymethod"), @args; - if (Param("maildeliverymethod") eq "testfile") { + my $mailer = new Mail::Mailer Param("mail_delivery_method"), @args; + if (Param("mail_delivery_method") eq "testfile") { $Mail::Mailer::testfile::config{outfile} = "$datadir/mailer.testfile"; } diff --git a/mozilla/webtools/bugzilla/checksetup.pl b/mozilla/webtools/bugzilla/checksetup.pl index 7fda5c97859..1464e851637 100755 --- a/mozilla/webtools/bugzilla/checksetup.pl +++ b/mozilla/webtools/bugzilla/checksetup.pl @@ -1282,10 +1282,10 @@ if (@oldparams) { close PARAMFILE; } -# Set maildeliverymethod to SMTP and prompt for SMTP server +# Set mail_delivery_method to SMTP and prompt for SMTP server # if running on Windows and set to sendmail (Mail::Mailer doesn't # support sendmail on Windows) -if ($^O =~ /MSWin32/i && Param('maildeliverymethod') eq 'sendmail') { +if ($^O =~ /MSWin32/i && Param('mail_delivery_method') eq 'sendmail') { print "\nBugzilla requires an SMTP server to function on Windows.\n" . "Please enter your SMTP server's hostname: "; my $smtp = $answer{'SMTP_SERVER'} @@ -1296,7 +1296,7 @@ if ($^O =~ /MSWin32/i && Param('maildeliverymethod') eq 'sendmail') { print "\nWarning: No SMTP Server provided, defaulting to localhost\n"; $smtp = 'localhost'; } - SetParam('maildeliverymethod', 'smtp'); + SetParam('mail_delivery_method', 'smtp'); SetParam('smtpserver', $smtp); } diff --git a/mozilla/webtools/bugzilla/defparams.pl b/mozilla/webtools/bugzilla/defparams.pl index b31f183979a..af5715235e7 100644 --- a/mozilla/webtools/bugzilla/defparams.pl +++ b/mozilla/webtools/bugzilla/defparams.pl @@ -671,24 +671,20 @@ sub find_languages { }, { - name => 'enable_mail_sending', - desc => 'If set to \'Off\', Bugzilla will not send out any email of any ' . - 'type whatsoever.
For most administrators, it is useful to ' . - 'be able to disable all mail during testing and initial setup, ' . - 'but other than that they will want to leave it \'On\'.', - type => 'b', - default => 1 - }, - - { - name => 'maildeliverymethod', - desc => 'The method used for mail delivery. The testfile method ' . - 'is useful for debugging (for more information see the ' . - 'Mail::Mailer manual)', + name => 'mail_delivery_method', + desc => 'Defines how email is sent, or if it is sent at all.
' , type => 's', choices => $^O =~ /MSWin32/i - ? ['smtp', 'testfile'] - : ['sendmail', 'smtp', 'qmail', 'testfile'], + ? ['smtp', 'testfile', 'none'] + : ['sendmail', 'smtp', 'qmail', 'testfile', 'none'], default => 'sendmail', checker => \&check_multi },