diff options
author | Eric Wong <e@80x24.org> | 2016-05-19 02:42:05 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2016-05-19 20:53:11 +0000 |
commit | 78042ed9abb2bbe9783adcc485365a8672e4b36f (patch) | |
tree | a1d1a8d539827d8ace692222c8c6f21a6fd8fb40 /lib/PublicInbox/Feed.pm | |
parent | 21a5cfeb30afef90ca888d425b62651466eed9e3 (diff) | |
download | public-inbox-78042ed9abb2bbe9783adcc485365a8672e4b36f.tar.gz |
This can be useful for lists where the convention is to attach (rather than inline) patches into the message body.
Diffstat (limited to 'lib/PublicInbox/Feed.pm')
-rw-r--r-- | lib/PublicInbox/Feed.pm | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/PublicInbox/Feed.pm b/lib/PublicInbox/Feed.pm index 0b864c2c..e2df97b1 100644 --- a/lib/PublicInbox/Feed.pm +++ b/lib/PublicInbox/Feed.pm @@ -315,10 +315,10 @@ sub add_to_feed { my $mid = $header_obj->header_raw('Message-ID'); defined $mid or return 0; $mid = PublicInbox::Hval->new_msgid($mid); - my $href = $mid->as_href; + my $href = $midurl.$mid->as_href; my $content = qq(<pre\nstyle="white-space:pre-wrap">) . - PublicInbox::View::multipart_text_as_html($mime) . + PublicInbox::View::multipart_text_as_html($mime, $href) . '</pre>'; my $date = $header_obj->header('Date'); my $updated = feed_updated($date); @@ -346,7 +346,7 @@ sub add_to_feed { my $h = '[a-f0-9]'; my (@uuid5) = ($add =~ m!\A($h{8})($h{4})($h{4})($h{4})($h{12})!o); my $id = 'urn:uuid:' . join('-', @uuid5); - $fh->write(qq!</div></content><link\nhref="$midurl$href/"/>!. + $fh->write(qq!</div></content><link\nhref="$href/"/>!. "<id>$id</id></entry>"); 1; } |