From b1f4cf8bdc4b49c02ebebbee2553202bc46ab720 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Tue, 4 Jul 2006 04:26:20 +0000 Subject: Bug 342869: Use Bugzilla->params everywhere except templates Patch By Max Kanat-Alexander r=LpSolit, a=justdave --- enter_bug.cgi | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'enter_bug.cgi') diff --git a/enter_bug.cgi b/enter_bug.cgi index 43b413431..929e690c8 100755 --- a/enter_bug.cgi +++ b/enter_bug.cgi @@ -70,7 +70,7 @@ if ($product_name eq '') { my @enterable_products = @{$user->get_enterable_products}; ThrowUserError('no_products') unless scalar(@enterable_products); - my $classification = Param('useclassification') ? + my $classification = Bugzilla->params->{'useclassification'} ? scalar($cgi->param('classification')) : '__all'; unless ($classification) { @@ -170,8 +170,8 @@ sub pickplatform { my @platform; - if (Param('defaultplatform')) { - @platform = Param('defaultplatform'); + if (Bugzilla->params->{'defaultplatform'}) { + @platform = Bugzilla->params->{'defaultplatform'}; } else { # If @platform is a list, this function will return the first # item in the list that is a valid platform choice. If @@ -228,8 +228,8 @@ sub pickos { my @os; - if (Param('defaultopsys')) { - @os = Param('defaultopsys'); + if (Bugzilla->params->{'defaultopsys'}) { + @os = Bugzilla->params->{'defaultopsys'}; } else { # This function will return the first # item in @os that is a valid platform choice. If @@ -367,8 +367,8 @@ if ($cloned_bug_id) { $vars->{'commentprivacy'} = 0; if ( !($isprivate) || - ( ( Param("insidergroup") ) && - ( UserInGroup(Param("insidergroup")) ) ) + ( ( Bugzilla->params->{"insidergroup"} ) && + ( UserInGroup(Bugzilla->params->{"insidergroup"}) ) ) ) { $vars->{'comment'} = $cloned_bug->{'longdescs'}->[0]->{'body'}; $vars->{'commentprivacy'} = $isprivate; @@ -382,8 +382,8 @@ if ($cloned_bug_id) { else { $default{'component_'} = formvalue('component'); - $default{'priority'} = formvalue('priority', Param('defaultpriority')); - $default{'bug_severity'} = formvalue('bug_severity', Param('defaultseverity')); + $default{'priority'} = formvalue('priority', Bugzilla->params->{'defaultpriority'}); + $default{'bug_severity'} = formvalue('bug_severity', Bugzilla->params->{'defaultseverity'}); $default{'rep_platform'} = pickplatform(); $default{'op_sys'} = pickos(); @@ -430,7 +430,7 @@ if ( ($cloned_bug_id) && } # Get list of milestones. -if ( Param('usetargetmilestone') ) { +if ( Bugzilla->params->{'usetargetmilestone'} ) { $vars->{'target_milestone'} = [map($_->name, @{$product->milestones})]; if (formvalue('target_milestone')) { $default{'target_milestone'} = formvalue('target_milestone'); -- cgit v1.2.3-24-g4f1b