From 854b5ff41747e65a7d628c61d3bb025b6b815750 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Mon, 10 Apr 2006 01:28:49 +0000 Subject: [PATCH] =?utf8?q?Bug=20332705:=20Taking=20a=20bug=20when=20postin?= =?utf8?q?g=20a=20new=20attachment=20doesn't=20update=20the=20'duplicates'?= =?utf8?q?=20table=20-=20Patch=20by=20Fr=C3=A9d=C3=A9ric=20Buclin=20=20r=3Dwicked=20a=3Djustdave?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- attachment.cgi | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/attachment.cgi b/attachment.cgi index 973b8b528d..09cde402f2 100755 --- a/attachment.cgi +++ b/attachment.cgi @@ -1071,7 +1071,11 @@ sub insert SendSQL("UPDATE bugs SET delta_ts = $sql_timestamp, " . join(", ", map("$fields[$_] = $newvalues[$_]", (0..3))) . " WHERE bug_id = $bugid"); - + + # If the bug was a dupe, we have to remove its entry from the + # 'duplicates' table. + $dbh->do('DELETE FROM duplicates WHERE dupe = ?', undef, $bugid); + # We store email addresses in the bugs_activity table rather than IDs. $oldvalues[0] = $oldvalues[4]; $newvalues[0] = $newvalues[4]; -- 2.47.2