]> Sergey Matveev's repositories - public-inbox.git/commitdiff
wwwatomstream: drop smsg->{mid} fallback for non-SQLite
authorEric Wong <e@yhbt.net>
Mon, 1 Jun 2020 10:06:57 +0000 (10:06 +0000)
committerEric Wong <e@yhbt.net>
Wed, 3 Jun 2020 04:04:21 +0000 (04:04 +0000)
It's no longer necessary to populate the smsg->{mid} field now
that ->smsg_eml calls smsg->populate in rare cases where the
smsg did not originate from SQLite.

lib/PublicInbox/WwwAtomStream.pm

index 6ed0cb212d6d790d5b9c4d8ea142b3052f5379c4..9dc24e16e9ff59c53c0bacd3ebe32c8efe480ab5 100644 (file)
@@ -12,7 +12,6 @@ use warnings;
 use POSIX qw(strftime);
 use Digest::SHA qw(sha1_hex);
 use PublicInbox::Address;
-use PublicInbox::MID qw(mids);
 use PublicInbox::Hval qw(ascii_html mid_href);
 use PublicInbox::MsgTime qw(msg_timestamp);
 
@@ -102,7 +101,7 @@ sub feed_entry {
        my $ctx = $self->{ctx};
        my $eml = $ctx->{-inbox}->smsg_eml($smsg) or return '';
        my $hdr = $eml->header_obj;
-       my $mid = $smsg->{mid} // mids($hdr)->[0];
+       my $mid = $smsg->{mid};
        my $irt = PublicInbox::View::in_reply_to($hdr);
        my $uuid = to_uuid($mid);
        my $base = $ctx->{feed_base_url};