From c0b2eaa8f0931bf4a037ccb596a0c0008a25f40a Mon Sep 17 00:00:00 2001 From: cjwatson <> Date: Thu, 18 Sep 2003 15:10:13 -0800 Subject: [PATCH] [project @ 2003-09-18 16:10:13 by cjwatson] Don't say things like "Will be archived: in -844 days" for already-archived bugs. --- cgi/common.pl | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cgi/common.pl b/cgi/common.pl index 8afd987..d9da34d 100644 --- a/cgi/common.pl +++ b/cgi/common.pl @@ -317,7 +317,11 @@ sub htmlindexentrystatus { } elsif (length($status{done})) { $result .= ";\nDone: " . htmlsanit($status{done}); $days = ceil($debbugs::gRemoveAge - -M buglog($status{id})); - $result .= ";\nWill be archived:" . ( $days == 0 ? " today" : $days == 1 ? " in $days day" : " in $days days" ); + if ($days >= 0) { + $result .= ";\nWill be archived:" . ( $days == 0 ? " today" : $days == 1 ? " in $days day" : " in $days days" ); + } else { + $result .= ";\nArchived"; + } } unless (length($status{done})) { -- 2.39.2