From 9dd7f90d71ee6d4ba533aee341c9dc44b06fcc6e Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Fri, 24 Jul 2020 05:55:59 +0000 Subject: [PATCH] xapcmd: set {from} properly for v1 inboxes This was a bug, but I'm not sure where it matters, yet, but it may matter in the future. --- lib/PublicInbox/Xapcmd.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/PublicInbox/Xapcmd.pm b/lib/PublicInbox/Xapcmd.pm index c04f935c..4ee3fc79 100644 --- a/lib/PublicInbox/Xapcmd.pm +++ b/lib/PublicInbox/Xapcmd.pm @@ -257,8 +257,9 @@ sub run { my $reindex; # v1:{ from => $x40 }, v2:{ from => [ $x40, $x40, .. ] } } if (!$opt->{-coarse_lock}) { - $reindex = $opt->{reindex} = {}; - $reindex->{from} = []; # per-epoch ranges + $reindex = $opt->{reindex} = { # per-epoch ranges for v2 + from => $ibx->version == 1 ? '' : [], + }; require PublicInbox::SearchIdx; PublicInbox::SearchIdx::load_xapian_writable(); } -- 2.44.0