diff options
author | Eric Wong <e@80x24.org> | 2021-02-04 00:59:26 -0900 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-02-05 00:16:31 +0000 |
commit | 69ea1bcb2983d2c51caf04440d4797212ed6fd64 (patch) | |
tree | cb948bde2534722b97b09dc7bc1d7188e38caa97 /lib/PublicInbox/Admin.pm | |
parent | a54a442b9a125f93518b8e50411403a708f8fc2e (diff) | |
download | public-inbox-69ea1bcb2983d2c51caf04440d4797212ed6fd64.tar.gz |
There's nothing we can do about bad emails in our search results, so quiet things down and don't fight the MUA for the terminal.
Diffstat (limited to 'lib/PublicInbox/Admin.pm')
-rw-r--r-- | lib/PublicInbox/Admin.pm | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/PublicInbox/Admin.pm b/lib/PublicInbox/Admin.pm index f96397ea..3b38a5a3 100644 --- a/lib/PublicInbox/Admin.pm +++ b/lib/PublicInbox/Admin.pm @@ -10,6 +10,7 @@ our @EXPORT_OK = qw(setup_signals); use PublicInbox::Config; use PublicInbox::Inbox; use PublicInbox::Spawn qw(popen_rd); +use PublicInbox::Eml; *rel2abs_collapsed = \&PublicInbox::Config::rel2abs_collapsed; sub setup_signals { @@ -241,12 +242,10 @@ sub index_inbox { } local %SIG = %SIG; setup_signals(\&index_terminate, $ibx); - my $warn_cb = $SIG{__WARN__} // \&CORE::warn; my $idx = { current_info => $ibx->{inboxdir} }; - my $warn_ignore = PublicInbox::InboxWritable->can('warn_ignore'); local $SIG{__WARN__} = sub { - return if $warn_ignore->(@_); - $warn_cb->($idx->{current_info}, ': ', @_); + return if PublicInbox::Eml::warn_ignore(@_); + warn($idx->{current_info}, ': ', @_); }; if (ref($ibx) && $ibx->version == 2) { eval { require PublicInbox::V2Writable }; |