From: Don Armstrong Date: Thu, 14 Jun 2007 18:33:02 +0000 (+0100) Subject: * Don't show time to archive for archived bugs X-Git-Tag: release/2.6.0~554^2~1 X-Git-Url: https://git.donarmstrong.com/?p=debbugs.git;a=commitdiff_plain;h=ad72f1e1665102eb4dfd402fc97b6f45090e9564 * Don't show time to archive for archived bugs * Handle summary being passed; guess log based on it. --- diff --git a/Debbugs/Status.pm b/Debbugs/Status.pm index bda64ab..312beac 100644 --- a/Debbugs/Status.pm +++ b/Debbugs/Status.pm @@ -172,6 +172,8 @@ sub read_bug{ } else { $status = $param{summary}; + $log = $status; + $log =~ s/\.summary$/.log/; } my $status_fh = new IO::File $status, 'r' or warn "Unable to open $status for reading: $!" and return undef; @@ -220,6 +222,7 @@ sub read_bug{ } # Add log last modified time $data{log_modified} = (stat($log))[9]; + $date{location} = $location; return \%data; } diff --git a/cgi/pkgreport.cgi b/cgi/pkgreport.cgi index 87525d9..cca0aaf 100755 --- a/cgi/pkgreport.cgi +++ b/cgi/pkgreport.cgi @@ -644,7 +644,7 @@ sub pkg_htmlindexentrystatus { status => \%status, days_until => 1, ); - if ($days >= 0) { + if ($days >= 0 and $status->{location} ne 'archive') { $result .= ";\nWill be archived" . ( $days == 0 ? " today" : $days == 1 ? " in $days day" : " in $days days" ) . ""; } }