From c15ee7a4d566c9e4911ac0cc0e94edb8d357709d Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Sun, 10 Apr 2005 06:18:16 +0000 Subject: Bug 225818: %FORM, %MFORM, and %COOKIE need to go away, in favor of the CGI methods - Patch by Teemu Mannermaa r=LpSolit a=myk --- process_bug.cgi | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'process_bug.cgi') diff --git a/process_bug.cgi b/process_bug.cgi index f85fd45d6..6f8303154 100755 --- a/process_bug.cgi +++ b/process_bug.cgi @@ -260,7 +260,7 @@ if (((defined $cgi->param('id') && $cgi->param('product') ne $oldproduct) && CheckonComment( "reassignbycomponent" )) { # Check to make sure they actually have the right to change the product - if (!CheckCanChangeField('product', $cgi->param('id'), $oldproduct, + if (!CheckCanChangeField('product', scalar $cgi->param('id'), $oldproduct, $cgi->param('product'))) { $vars->{'oldvalue'} = $oldproduct; $vars->{'newvalue'} = $cgi->param('product'); @@ -614,7 +614,7 @@ sub DoComma { } sub DoConfirm { - if (CheckCanChangeField("canconfirm", $cgi->param('id'), 0, 1)) { + if (CheckCanChangeField("canconfirm", scalar $cgi->param('id'), 0, 1)) { DoComma(); $::query .= "everconfirmed = 1"; } @@ -1301,8 +1301,7 @@ foreach my $id (@idlist) { { product => $oldhash{'product'} }); } - if (defined $cgi->param('product') - && $cgi->param('product') ne $cgi->param('dontchange') + if ($cgi->param('product') ne $cgi->param('dontchange') && $cgi->param('product') ne $oldhash{'product'} && !CanEnterProduct($cgi->param('product'))) { ThrowUserError("entry_access_denied", @@ -1494,9 +1493,7 @@ foreach my $id (@idlist) { } my $newproduct_id = $oldhash{'product_id'}; - if ((defined $cgi->param('product')) - && ($cgi->param('product') ne $cgi->param('dontchange'))) - { + if ($cgi->param('product') ne $cgi->param('dontchange')) { my $newproduct_id = get_product_id($cgi->param('product')); } @@ -1648,8 +1645,7 @@ foreach my $id (@idlist) { # conditions under which these activities take place, more information # about which can be found in comments within the conditionals below. # Check if the user has changed the product to which the bug belongs; - if (defined $cgi->param('product') - && $cgi->param('product') ne $cgi->param('dontchange') + if ($cgi->param('product') ne $cgi->param('dontchange') && $cgi->param('product') ne $oldhash{'product'} ) { $newproduct_id = get_product_id($cgi->param('product')); -- cgit v1.2.3-24-g4f1b