]> Sergey Matveev's repositories - public-inbox.git/commit
inbox: simplify ->search and callers
authorEric Wong <e@80x24.org>
Sat, 5 Dec 2020 10:11:37 +0000 (10:11 +0000)
committerEric Wong <e@80x24.org>
Sat, 5 Dec 2020 21:41:52 +0000 (21:41 +0000)
commit89990b0cfc8bbdabc8d650325d9e1bc585df8a0c
treece962a5a8d00ed83c3f6caa5c1e5e91ec1966aaf
parent8e0aef5068aa71e58d4a049491229f41e6bf19fb
inbox: simplify ->search and callers

Stop leaking WWW/PSGI-specific logic into classes like
PublicInbox::Inbox, which is used universally.

We'll also decouple $ibx->over from $ibx->search and just deal
with duplicate the code inside ->over to reduce argument
complexity in ->search.

This is also a step in moving away from using {psgi.errors}
to ease code sharing between IMAP, NNTP, and command-line
interfaces.  Perl's built-in `warn' and `local $SIG{__WARN__}'
provides all the flexibility we need to control warning output
and should be universally understood by Perl hackers who may
be unfamiliar with PSGI.
lib/PublicInbox/Inbox.pm
lib/PublicInbox/Mbox.pm