X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scripts%2Fprocess;h=3da8f983c4a13ea773fe808a6f8136018b918a9d;hb=6c674e3570221c96734f94967ad55f50560bee54;hp=91b68613c2d01e27155db9852d838aae245b1345;hpb=6617fa4e20357b7c2bb9f5990984b08d4f827089;p=debbugs.git diff --git a/scripts/process b/scripts/process index 91b6861..3da8f98 100755 --- a/scripts/process +++ b/scripts/process @@ -34,6 +34,7 @@ use Debbugs::Control qw(append_action_to_log); use Debbugs::Control::Service qw(valid_control control_line); use Debbugs::Recipients qw(determine_recipients); use Encode qw(encode_utf8 decode); +use List::AllUtils qw(first uniqnum); =head1 NAME @@ -1273,20 +1274,15 @@ sub fill_template{ my $variables = {config => \%config, defined($ref)?(ref => $ref):(), defined($data)?(data => $data):(), - refs => [map {exists $clonebugs{$_}?$clonebugs{$_}:$_} keys %bug_affected], + refs => [sort + uniqnum(defined($ref)?($ref):(), + map {exists $clonebugs{$_}?$clonebugs{$_}:$_} + keys %bug_affected)], %{$extra_var}, }; - my $hole_var = {'&bugurl' => - sub{"$_[0]: ". - $config{cgi_domain}.'/'. - Debbugs::CGI::bug_links(bug=>$_[0], - links_only => 1, - ); - } - }; return fill_in_template(template => $template, variables => $variables, - hole_var => $hole_var, + output_type => 'text', ); }