From 3fc59df0d633a17e0c5e43d633d12e8772c06ec3 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Tue, 10 Jan 2017 21:40:37 +0000 Subject: introduce PublicInbox::MIME wrapper class This should fix problems with multipart messages where text/plain parts lack a header. cf. git clone --mirror https://github.com/rjbs/Email-MIME.git refs/pull/28/head In the future, we may still introduce as streaming interface to reduce memory usage on large emails. --- lib/PublicInbox/Feed.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lib/PublicInbox/Feed.pm') diff --git a/lib/PublicInbox/Feed.pm b/lib/PublicInbox/Feed.pm index 2a33fd29..e5d57550 100644 --- a/lib/PublicInbox/Feed.pm +++ b/lib/PublicInbox/Feed.pm @@ -5,7 +5,7 @@ package PublicInbox::Feed; use strict; use warnings; -use Email::MIME; +use PublicInbox::MIME; use PublicInbox::View; use PublicInbox::WwwAtomStream; @@ -39,7 +39,7 @@ sub generate_thread_atom { PublicInbox::WwwAtomStream->response($ctx, 200, sub { while (my $msg = shift @$msgs) { $msg = $ibx->msg_by_smsg($msg) and - return Email::MIME->new($msg); + return PublicInbox::MIME->new($msg); } }); } @@ -175,7 +175,7 @@ sub each_recent_blob { sub do_cat_mail { my ($ibx, $path) = @_; my $mime = eval { $ibx->msg_by_path($path) } or return; - Email::MIME->new($mime); + PublicInbox::MIME->new($mime); } 1; -- cgit v1.2.3-24-ge0c7