X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=cgi%2Fcommon.pl;h=05b8941ac7f84f8a2d2e07b9556ba9c6cabf577c;hb=62cac6b6d596b6f29286adf2e6781405f9fd04e9;hp=4701006e378dbe7de0b5ec02c54806a11ba3b7b4;hpb=3a63bf2b966adce2531457567c38e31f486e2efe;p=debbugs.git diff --git a/cgi/common.pl b/cgi/common.pl index 4701006..05b8941 100644 --- a/cgi/common.pl +++ b/cgi/common.pl @@ -454,7 +454,7 @@ sub allbugs { return @{getbugs(sub { 1 })}; } -sub bugmatches(\%\%) { +sub bugmatches { my ($hash, $status) = @_; foreach my $key( keys( %$hash ) ) { my $value = $hash->{$key}; @@ -463,14 +463,14 @@ sub bugmatches(\%\%) { } return 0; } -sub bugfilter($%) { - my ($bug, %status) = @_; - our (%seenmerged); - if (%common_include) { - return 1 if (!bugmatches(%common_include, %status)); - } - if (%common_exclude) { - return 1 if (bugmatches(%common_exclude, %status)); +sub bugfilter { + my ($bug, $status,$seen_merged,$common_include,$common_exclude,$repeat_merged,) = @_; + #our (%seenmerged); + if ($common_include) { + return 1 if (!bugmatches($common_include, $status)); + } + if ($common_exclude) { + return 1 if (bugmatches($common_exclude, $status)); } my @merged = sort {$a<=>$b} $bug, split(/ /, $status{mergedwith}); my $daysold = int((time - $status{date}) / 86400); # seconds to days