- while (<$fh>) {
- ($cmt, $type) = split / /;
- next if $type ne 'blob';
- ++$n;
- $str = $git->cat_file($cmt);
- $mime = PublicInbox::MIME->new($str);
- PublicInbox::View::multipart_text_as_html($mime, '../', $ctx);
- $obuf = '';
+ $ctx->{mhref} = '../';
+ if (defined $blob) {
+ my $nr = $ENV{NR} // 10000;
+ for (1..$nr) {
+ ++$n;
+ $git->cat_async($blob, $cb);
+ }
+ } else {
+ while (<$fh>) {
+ ($oid, $type) = split / /;
+ next if $type ne 'blob';
+ ++$n;
+ $git->cat_async($oid, $cb);
+ }