]> Sergey Matveev's repositories - public-inbox.git/commitdiff
extsearchidx: no need to make InboxWritable
authorEric Wong <e@80x24.org>
Wed, 16 Dec 2020 23:19:06 +0000 (23:19 +0000)
committerEric Wong <e@80x24.org>
Thu, 17 Dec 2020 19:41:16 +0000 (19:41 +0000)
extindex treats v1/v2 public inboxes as read-only, so there's
no need to scare people by using the InboxWritable package
now that ->git_dir_n is gone and we can use ->max_git_epoch
instead of ->git_dir_latest.

lib/PublicInbox/ExtSearchIdx.pm

index 3764612cf149c9281c9b8e3b21603f3c0e859486..c6fb398beec13d90da2c9ba44a660ba343488682 100644 (file)
@@ -63,7 +63,6 @@ sub new {
 
 sub attach_inbox {
        my ($self, $ibx) = @_;
-       $ibx = PublicInbox::InboxWritable->new($ibx);
        my $key = $ibx->eidx_key;
        if (!$ibx->over || !$ibx->mm) {
                warn "W: skipping $key (unindexed)\n";
@@ -78,7 +77,6 @@ sub attach_inbox {
                warn "W: `$ibx->{inboxdir}' canonicalized to `$ibxdir'\n";
                $ibx->{inboxdir} = $ibxdir;
        }
-       $ibx = PublicInbox::InboxWritable->new($ibx);
        $self->{ibx_map}->{$key} //= do {
                push @{$self->{ibx_list}}, $ibx;
                $ibx;