Commit 234bfc8f authored by justdave%bugzilla.org's avatar justdave%bugzilla.org

Bug 256004: Fix regression that caused duplicate sortkeys in the fielddefs table

r=myk, a=justdave
parent 2ac9cabf
......@@ -2138,11 +2138,11 @@ sub AddFDef ($$$) {
$dbh->do("INSERT INTO fielddefs " .
"(fieldid, name, description, mailhead, sortkey) VALUES " .
"($fieldid, $name, $description, $mailhead, $headernum)");
$headernum++;
} else {
$dbh->do("UPDATE fielddefs SET name = $name, description = $description, " .
"mailhead = $mailhead WHERE fieldid = $fieldid");
"mailhead = $mailhead, sortkey = $headernum WHERE fieldid = $fieldid");
}
$headernum++;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment