]> git.donarmstrong.com Git - debbugs.git/commitdiff
[project @ 2003-04-26 00:47:31 by cjwatson]
authorcjwatson <>
Sat, 26 Apr 2003 07:47:31 +0000 (23:47 -0800)
committercjwatson <>
Sat, 26 Apr 2003 07:47:31 +0000 (23:47 -0800)
Only show a link to the source package if it's non-trivial, i.e. isn't just
a single-binary source with the same name.

cgi/pkgreport.cgi

index 699365ccaaf71a6d1e8f9f495e54c74b9eaf1ce1..fdf5709d8807300170b9e46982e9b8dc438df91f 100755 (executable)
@@ -221,7 +221,10 @@ if (defined $pkg || defined $src) {
                if (defined $debbugs::gSubscriptionDomain) {
                    push @references, "to the <a href=\"http://$debbugs::gSubscriptionDomain/$srcforpkg\">Package Tracking System</a>";
                }
-               push @references, sprintf "to the source package <a href=\"%s\">%s</a>'s bug page", srcurl($srcforpkg), htmlsanit($srcforpkg);
+               # Only output this if the source listing is non-trivial.
+               if (@pkgs or $pkg ne $srcforpkg) {
+                   push @references, sprintf "to the source package <a href=\"%s\">%s</a>'s bug page", srcurl($srcforpkg), htmlsanit($srcforpkg);
+               }
            }
            if (@references) {
                $references[$#references] = "or $references[$#references]" if @references > 1;