]> Sergey Matveev's repositories - public-inbox.git/commitdiff
lei/store: use remove_doc to save some LoC
authorEric Wong <e@80x24.org>
Tue, 12 Oct 2021 22:44:57 +0000 (22:44 +0000)
committerEric Wong <e@80x24.org>
Wed, 13 Oct 2021 00:41:22 +0000 (00:41 +0000)
lib/PublicInbox/LeiStore.pm

index 613d1d31f58136b53cd48533f7869e17522c5329..bf41dcf530942a9bc57ef8530a8629bc94906753 100644 (file)
@@ -281,8 +281,7 @@ sub remove_docids ($;@) {
        my ($self, @docids) = @_;
        my $eidx = eidx_init($self);
        for my $docid (@docids) {
-               $eidx->idx_shard($docid)->ipc_do('xdb_remove', $docid);
-               $eidx->{oidx}->delete_by_num($docid);
+               $eidx->remove_doc($docid);
                $eidx->{oidx}->{dbh}->do(<<EOF, undef, $docid);
 DELETE FROM xref3 WHERE docid = ?
 EOF