about summary refs log tree commit homepage
path: root/lib/PublicInbox/SearchIdx.pm
diff options
context:
space:
mode:
authorEric Wong <e@80x24.org>2020-01-03 08:46:03 +0000
committerEric Wong <e@80x24.org>2020-01-04 09:35:05 +0000
commit2b189b48dee50f43042ba0f23ff374f62413fb2e (patch)
tree8bd28a344f5a9cff8d2fb1de1bc0a391382262b5 /lib/PublicInbox/SearchIdx.pm
parent65631cff59d920114f203ce67fbe222729957a82 (diff)
downloadpublic-inbox-2b189b48dee50f43042ba0f23ff374f62413fb2e.tar.gz
It shouldn't be possible for v1 inboxes to have multiple matches
for a given Message-ID, so the sub would only get called once,
but strange things could happen in 2112 :>
Diffstat (limited to 'lib/PublicInbox/SearchIdx.pm')
-rw-r--r--lib/PublicInbox/SearchIdx.pm2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/SearchIdx.pm b/lib/PublicInbox/SearchIdx.pm
index ca1457fd..0d983aab 100644
--- a/lib/PublicInbox/SearchIdx.pm
+++ b/lib/PublicInbox/SearchIdx.pm
@@ -433,7 +433,7 @@ sub remove_message {
                 batch_do($self, 'Q' . $mid, sub {
                         my ($ids) = @_;
                         $db->delete_document($_) for @$ids;
-                        $nr = scalar @$ids;
+                        $nr += scalar @$ids;
                 });
         };
         if ($@) {