]> git.donarmstrong.com Git - debbugs.git/commitdiff
merge changes from dla source tree
authorDebian BTS <debbugs@rietz>
Tue, 26 Jun 2007 18:35:20 +0000 (18:35 +0000)
committerDebian BTS <debbugs@rietz>
Tue, 26 Jun 2007 18:35:20 +0000 (18:35 +0000)
Debbugs/Bugs.pm
Debbugs/Status.pm
cgi/pkgreport.cgi

index 848931f79b8fcca9799324a814630ee2d77666a8..010d671618d20c05e9883d47463c0d67664626de 100644 (file)
@@ -415,20 +415,13 @@ sub get_bugs_by_idx{
      my @packages = __handle_pkg_src_and_maint(map {exists $param{$_}?($_,$param{$_}):()}
                                               qw(package src maint)
                                              );
-     my %usertag_bugs;
-     if (exists $param{tag} and exists $param{usertags}) {
-         # This complex slice makes a hash with the bugs which have the
-          # usertags passed in $param{tag} set.
-         @usertag_bugs{make_list(@{$param{usertags}}{make_list($param{tag})})
-                       } = (1) x make_list(@{$param{usertags}}{make_list($param{tag})});
-     }
      if (exists $param{package} or
         exists $param{src} or
         exists $param{maint}) {
          delete @param{qw(maint src)};
          $param{package} = [@packages];
      }
-     my $keys = keys(%param) - 1;
+     my $keys = grep {$_ !~ /^(archive|usertags|bugs)$/} keys(%param);
      die "Need at least 1 key to search by" unless $keys;
      my $arc = $param{archive} ? '-arc':'';
      my %idx;
index 6b6fabd3654442c21be344740b31e578268a860e..dac6d75944aee1c29f80f2d9fbf615caab30343b 100644 (file)
@@ -739,7 +739,7 @@ currently not correctly implemented.
 
 =item arch -- optional architecture(s) to check package status at
 
-=item usertags -- optional hashref of usertags
+=item bugusertags -- optional hashref of bugusertags
 
 =item sourceversion -- optional arrayref of source/version; overrides
 dist, arch, and version. [The entries in this array must be in the
@@ -775,9 +775,9 @@ sub get_bug_status {
                                          arch       => {type => SCALAR|ARRAYREF,
                                                         optional => 1,
                                                        },
-                                         usertags   => {type => HASHREF,
-                                                        optional => 1,
-                                                       },
+                                         bugusertags   => {type => HASHREF,
+                                                           optional => 1,
+                                                          },
                                          sourceversions => {type => ARRAYREF,
                                                             optional => 1,
                                                            },
@@ -802,10 +802,10 @@ sub get_bug_status {
      }
      $status{id} = $param{bug};
 
-     if (defined $param{usertags}{$param{bug}}) {
+     if (defined $param{bugusertags}{$param{bug}}) {
          $status{keywords} = "" unless defined $status{keywords};
          $status{keywords} .= " " unless $status{keywords} eq "";
-         $status{keywords} .= join(" ", @{$param{usertags}{$param{bug}}});
+         $status{keywords} .= join(" ", @{$param{bugusertags}{$param{bug}}});
      }
      $status{tags} = $status{keywords};
      my %tags = map { $_ => 1 } split ' ', $status{tags};
index cffc324bc02b0d4a0dc93c8c57d856b03cc11243..f386655c0a1c1de463446812d4e6fd7917215f17 100755 (executable)
@@ -326,8 +326,9 @@ if (defined $param{maint} and $param{maint} eq "") {
 }
 else {
      #yeah for magick!
-     @bugs = get_bugs(map {exists $param{$_}?($_,$param{$_}):()}
-                     keys %search_keys, 'archive'
+     @bugs = get_bugs((map {exists $param{$_}?($_,$param{$_}):()}
+                      keys %search_keys, 'archive'),
+                     usertags => \%ut,
                     );
 }
 
@@ -735,7 +736,7 @@ sub pkg_htmlizebugs {
     foreach my $bug (@bugs) {
         my %status = %{get_bug_status(bug=>$bug,
                                      (exists $param{dist}?(dist => $param{dist}):()),
-                                     usertags => \%bugusertags,
+                                     bugusertags => \%bugusertags,
                                      (exists $param{version}?(version => $param{version}):()),
                                      (exists $param{arch}?(arch => $param{arch}):()),
                                     )};