]> Sergey Matveev's repositories - public-inbox.git/blobdiff - lib/PublicInbox/LeiRefreshMailSync.pm
lei: lock worker counts
[public-inbox.git] / lib / PublicInbox / LeiRefreshMailSync.pm
index 09a7ead06a0a43c1078b93816a826aa5a3019516..cdd997253a609dc5871bdb7e9b17c88aa1468bce 100644 (file)
@@ -84,11 +84,9 @@ EOM
        my $self = bless { missing_ok => 1 }, __PACKAGE__;
        $lei->{opt}->{'mail-sync'} = 1; # for prepare_inputs
        $self->prepare_inputs($lei, \@folders) or return;
-       my $j = $lei->{opt}->{jobs} || scalar(@{$self->{inputs}}) || 1;
        my $ops = {};
        $lei->{auth}->op_merge($ops, $self) if $lei->{auth};
-       $self->{-wq_nr_workers} = $j // 1; # locked
-       (my $op_c, $ops) = $lei->workers_start($self, $j, $ops);
+       (my $op_c, $ops) = $lei->workers_start($self, 1, $ops);
        $lei->{wq1} = $self;
        $lei->{-err_type} = 'non-fatal';
        net_merge_all_done($self) unless $lei->{auth};