From: lpsolit%gmail.com <> Date: Fri, 3 Jun 2005 04:28:05 +0000 (+0000) Subject: Bug 295213: whine mail still goes out even though whinedays = "0" - Patch by Marc... X-Git-Tag: bugzilla-2.18.2~23 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5e8edf843da67631e37f3fd5d3d15ba0cbc5fad4;p=thirdparty%2Fbugzilla.git Bug 295213: whine mail still goes out even though whinedays = "0" - Patch by Marc Schumann r=LpSolit a=myk --- diff --git a/defparams.pl b/defparams.pl index 323b91edbb..5f709c43ee 100644 --- a/defparams.pl +++ b/defparams.pl @@ -570,8 +570,9 @@ Configure bugmail: %urlbase%userprefs.cgi?tab=email { name => 'whinedays', - desc => 'The number of days that we\'ll let a bug sit untouched in a NEW ' . - 'state before our cronjob will whine at the owner.', + desc => q{The number of days that we'll let a bug sit untouched in a NEW + state before our cronjob will whine at the owner.
+ Set to 0 to disable whining.}, type => 't', default => 7 }, diff --git a/whineatnews.pl b/whineatnews.pl index c8bad23d77..355f62cca3 100755 --- a/whineatnews.pl +++ b/whineatnews.pl @@ -33,6 +33,9 @@ require "globals.pl"; use Bugzilla::BugMail; +# Whining is disabled if whinedays is zero +exit unless Param('whinedays') >= 1; + SendSQL("select bug_id,short_desc,login_name from bugs,profiles where " . "(bug_status = 'NEW' or bug_status = 'REOPENED') and " . "to_days(now()) - to_days(delta_ts) > " . Param('whinedays') .