]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Fix for bug 74394: editmilestones.cgi can't edit the name and sortkey at the same...
authorjustdave%syndicomm.com <>
Fri, 6 Apr 2001 23:47:49 +0000 (23:47 +0000)
committerjustdave%syndicomm.com <>
Fri, 6 Apr 2001 23:47:49 +0000 (23:47 +0000)
Patch by slee@uk.bnsmc.com (Stephen Lee)

editmilestones.cgi

index 9eadeeba2dcbb343c9382f91127ae6971f17b69a..57fe78830d514a99cabf5caf6645e13652f460af 100755 (executable)
@@ -513,6 +513,13 @@ if ($action eq 'update') {
                          milestones WRITE,
                          products WRITE");
 
+    if ($sortkey != $sortkeyold) {
+        SendSQL("UPDATE milestones SET sortkey=$sortkey
+                 WHERE product=" . SqlQuote($product) . "
+                   AND value=" . SqlQuote($milestoneold));
+        unlink "data/versioncache";
+        print "Updated sortkey.<BR>\n";
+    }
     if ($milestone ne $milestoneold) {
         unless ($milestone) {
             print "Sorry, I can't delete the milestone text.";
@@ -541,13 +548,6 @@ if ($action eq 'update') {
         unlink "data/versioncache";
         print "Updated milestone.<BR>\n";
     }
-    if ($sortkey != $sortkeyold) {
-        SendSQL("UPDATE milestones SET sortkey=$sortkey
-                 WHERE product=" . SqlQuote($product) . "
-                   AND value=" . SqlQuote($milestoneold));
-        unlink "data/versioncache";
-        print "Updated sortkey.<BR>\n";
-    }
     SendSQL("UNLOCK TABLES");
 
     PutTrailer($localtrailer);