]> git.donarmstrong.com Git - debbugs.git/blobdiff - lib/Debbugs/Bug.pm
only complain about there not being a db when there should be one
[debbugs.git] / lib / Debbugs / Bug.pm
index 21a26e39af2c443e34c0b260887d29146f1fc225..b3e95cd1b266426323b638a190dce42e51d0b62e 100644 (file)
@@ -119,7 +119,9 @@ sub _build_package_collection {
     if ($self->has_schema) {
         return Debbugs::Collection::Package->new(schema => $self->schema);
     }
-    carp "No schema when building package collection";
+    if (defined $config{database}) {
+        carp "No schema when building package collection";
+    }
     return Debbugs::Collection::Package->new();
 }
 
@@ -464,8 +466,8 @@ sub _populate_archiveable {
        }
     }
     my $time = time;
-    state $remove_time = 24 * 60 * 60 * ($config{removal_age} // 30);
-    # 4. Have been modified more than removal_age ago
+    state $remove_time = 24 * 60 * 60 * ($config{remove_age} // 30);
+    # 4. Have been modified more than remove_age ago
     my $moded_ago =
        $time - $self->modified->epoch;
     # if we don't need to know when we can archive, we can stop here if it's
@@ -657,6 +659,7 @@ sub related_packages_and_versions {
            push @return,$pkg;
         }
     }
+    push @return,$self->status->affects;
     return @return;
 }