-sub input_mbox_cb { input_eml_cb($_[1], $_[0]) }
-
-sub _lei_wq_eof { # EOF callback for main daemon
- my ($lei) = @_;
- my $tag = delete $lei->{tag} // return $lei->dclose;
- $tag->wq_wait_old($lei->can('wq_done_wait'), $lei, 'non-fatal');
-}
-
-sub net_merge_complete { # callback used by LeiAuth
- my ($self) = @_;
- $self->wq_io_do('process_inputs');
- $self->wq_close(1);
-}
-
-sub input_maildir_cb { # maildir_each_eml cb
- my ($f, $kw, $eml, $self) = @_;
- input_eml_cb($self, $eml);
-}
-
-sub input_net_cb { # imap_each, nntp_each cb
- my ($url, $uid, $kw, $eml, $self) = @_;
+sub pmdir_cb { # called via wq_io_do from LeiPmdir->each_mdir_fn
+ my ($self, $f) = @_;
+ my $eml = eml_from_path($f) or return;