]> git.donarmstrong.com Git - debbugs.git/commitdiff
don't alter archived bugs in control
authorDon Armstrong <don@donarmstrong.com>
Thu, 6 Aug 2009 15:58:43 +0000 (08:58 -0700)
committerDon Armstrong <don@donarmstrong.com>
Thu, 6 Aug 2009 15:58:43 +0000 (08:58 -0700)
Debbugs/Control.pm

index a36321a4ee2cf6f3469adf37309c0bb7e13e46ff..c80a3ce0415337328be9dd995d8409069318d88d 100644 (file)
@@ -2685,6 +2685,13 @@ sub __begin_control {
     if (not @data) {
        die "Unable to read any bugs successfully.";
     }
+    if (not $param{archived}) {
+       for my $data (@data) {
+           if ($data->{archived}) {
+               die "Not altering archived bugs; see unarchive.";
+           }
+       }
+    }
     if (not __check_limit(data => \@data,
                          exists $param{limit}?(limit => $param{limit}):(),
                         )) {