]> Sergey Matveev's repositories - public-inbox.git/commitdiff
lei mail-diff: do not default to 'eml'
authorEric Wong <e@80x24.org>
Tue, 2 Nov 2021 18:14:43 +0000 (18:14 +0000)
committerEric Wong <e@80x24.org>
Tue, 2 Nov 2021 19:03:39 +0000 (19:03 +0000)
In retrospect, this doesn't make sense, since it needs at least
two messages to diff.  So go about "normal" input rules and
require users to specify the format.

lib/PublicInbox/LeiMailDiff.pm

index b21a0c366fd68aa6c8198a99e7bbf5b7f9ea8cca..48ba74cfe886f1811aa078670491ebce8f44eb09 100644 (file)
@@ -76,7 +76,6 @@ sub input_eml_cb { # used by PublicInbox::LeiInput::input_fh
 
 sub lei_mail_diff {
        my ($lei, @argv) = @_;
-       $lei->{opt}->{'in-format'} //= 'eml' if !grep(/\A[a-z0-9]+:/i, @argv);
        my $self = bless {}, __PACKAGE__;
        $self->prepare_inputs($lei, \@argv) or return;
        my $isatty = -t $lei->{1};