]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/LeiOverview.pm
lei: show {pct} and {oid} in From_ lines and filenames
[public-inbox.git] / lib / PublicInbox / LeiOverview.pm
index 47d9eb318f821daea650b39ef15dc5c4c0d8d805..7a4fa85740c3d8b4f5442e10934e5a99ab7ffa71 100644 (file)
@@ -224,8 +224,9 @@ sub ovv_each_smsg_cb { # runs in wq worker usually
                my $git_dir = $git->{git_dir};
                sub {
                        my ($smsg, $mitem) = @_;
-                       $l2m->wq_do('write_mail', \@io, $git_dir,
-                                       $smsg->{blob}, $lei_ipc, $smsg->{kw});
+                       $smsg->{pct} = get_pct($mitem) if $mitem;
+                       $l2m->wq_do('write_mail', \@io, $git_dir, $smsg,
+                                       $lei_ipc);
                }
        } elsif ($l2m) {
                my $wcb = $l2m->write_cb($lei);
@@ -234,8 +235,8 @@ sub ovv_each_smsg_cb { # runs in wq worker usually
                my $g2m = $l2m->can('git_to_mail');
                sub {
                        my ($smsg, $mitem) = @_;
-                       $git->cat_async($smsg->{blob}, $g2m,
-                                       [ $wcb, $smsg->{kw} ]);
+                       $smsg->{pct} = get_pct($mitem) if $mitem;
+                       $git->cat_async($smsg->{blob}, $g2m, [ $wcb, $smsg ]);
                };
        } elsif ($self->{fmt} =~ /\A(concat)?json\z/ && $lei->{opt}->{pretty}) {
                my $EOR = ($1//'') eq 'concat' ? "\n}" : "\n},";