diff options
author | bugreport%peshkin.net <> | 2002-10-31 23:45:19 +0100 |
---|---|---|
committer | bugreport%peshkin.net <> | 2002-10-31 23:45:19 +0100 |
commit | cf6262d55a4d22906625cf659d94736515393122 (patch) | |
tree | 47d56bcd86a623f9fa447b7c5ac9bac6042d59fc | |
parent | 4fc0668c40ac6e71b5418d6cbc2127eeb4e97c91 (diff) | |
download | bugzilla-cf6262d55a4d22906625cf659d94736515393122.tar.gz bugzilla-cf6262d55a4d22906625cf659d94736515393122.tar.xz |
Bug 95430 Reopening en masse fails.
Patch by jeff.hedlund
r=justdave, joel
-rwxr-xr-x | process_bug.cgi | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/process_bug.cgi b/process_bug.cgi index bf0edc09c..0450b7ce9 100755 --- a/process_bug.cgi +++ b/process_bug.cgi @@ -898,12 +898,8 @@ SWITCH: for ($::FORM{'knob'}) { last SWITCH; }; /^reopen$/ && CheckonComment( "reopen" ) && do { - SendSQL("SELECT resolution FROM bugs WHERE bug_id = $::FORM{'id'}"); ChangeStatus('REOPENED'); ChangeResolution(''); - if (FetchOneColumn() eq 'DUPLICATE') { - SendSQL("DELETE FROM duplicates WHERE dupe = $::FORM{'id'}"); - } last SWITCH; }; /^verify$/ && CheckonComment( "verify" ) && do { @@ -1058,7 +1054,7 @@ foreach my $id (@idlist) { "profiles $write, dependencies $write, votes $write, " . "products READ, components READ, " . "keywords $write, longdescs $write, fielddefs $write, " . - "bug_group_map $write, flags $write, " . + "bug_group_map $write, flags $write, duplicates $write," . "user_group_map READ, flagtypes READ, " . "flaginclusions AS i READ, flagexclusions AS e READ, " . "keyworddefs READ, groups READ, attachments READ"); @@ -1243,6 +1239,13 @@ foreach my $id (@idlist) { if ($::comma ne "") { SendSQL($query); } + # Check for duplicates if the bug is [re]open + SendSQL("SELECT resolution FROM bugs WHERE bug_id = $id"); + my $resolution = FetchOneColumn(); + if ($resolution eq '') { + SendSQL("DELETE FROM duplicates WHERE dupe = $id"); + } + my @groupAddNames = (); foreach my $grouptoadd (@groupAdd) { if (!BugInGroupId($id, $grouptoadd)) { |