]> git.donarmstrong.com Git - debbugs.git/commitdiff
[project @ 2005-07-27 22:51:25 by don]
authordon <>
Thu, 28 Jul 2005 05:51:25 +0000 (21:51 -0800)
committerdon <>
Thu, 28 Jul 2005 05:51:25 +0000 (21:51 -0800)
* Return to the previous mailbox download default of showing only the
   non-boring messages. Boring messages can now be shown by adding
   &boring=yes to the url.

cgi/bugreport.cgi

index 8df1db8ece7586a53c9b555503d99f5e5705dc31..090cc8107239d21edaa750cf5c3c668fc55306e6 100755 (executable)
@@ -400,22 +400,23 @@ if ( $mbox ) {
          print qq(Content-Disposition: attachment; filename="bug_${ref}_message_${msg_num}.mbox"\n);
          print "Content-Type: message/rfc822\n\n";
      }
-       for my $record (@records) {
-            next if $record->{type} !~ /^(?:recips|incoming-recv)$/;
-            my @lines = split( "\n", $record->{text}, -1 );
-            if ( $lines[ 1 ] =~ m/^From / ) {
-                 my $tmp = $lines[ 0 ];
-                 $lines[ 0 ] = $lines[ 1 ];
-                 $lines[ 1 ] = $tmp;
-            }
-            if ( !( $lines[ 0 ] =~ m/^From / ) ) {
-                 my $date = strftime "%a %b %d %T %Y", localtime;
-                 unshift @lines, "From unknown $date";
-            }
-            map { s/^(>*From )/>$1/ } @lines[ 1 .. $#lines ];
-            print join( "\n", @lines ) . "\n";
-       }
-       exit 0;
+     for my $record (@records) {
+         next if $record->{type} !~ /^(?:recips|incoming-recv)$/;
+         next if not $boring and $record->{type} eq 'recips';
+         my @lines = split( "\n", $record->{text}, -1 );
+         if ( $lines[ 1 ] =~ m/^From / ) {
+              my $tmp = $lines[ 0 ];
+              $lines[ 0 ] = $lines[ 1 ];
+              $lines[ 1 ] = $tmp;
+         }
+         if ( !( $lines[ 0 ] =~ m/^From / ) ) {
+              my $date = strftime "%a %b %d %T %Y", localtime;
+              unshift @lines, "From unknown $date";
+         }
+         map { s/^(>*From )/>$1/ } @lines[ 1 .. $#lines ];
+         print join( "\n", @lines ) . "\n";
+     }
+     exit 0;
 }
 
 else {