From dda6cc91f8fbaaac187366957be6b828496e12f8 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sun, 5 Jul 2020 23:27:22 +0000 Subject: www: need: use WwwStream::html_oneshot It'll give us a nicer HTML header and footer. --- lib/PublicInbox/WWW.pm | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'lib/PublicInbox/WWW.pm') diff --git a/lib/PublicInbox/WWW.pm b/lib/PublicInbox/WWW.pm index 289d0ce4..e4ad515a 100644 --- a/lib/PublicInbox/WWW.pm +++ b/lib/PublicInbox/WWW.pm @@ -322,12 +322,11 @@ sub get_altid_dump { sub need { my ($ctx, $extra) = @_; - my $msg = <$extra not available for this -public-inbox
$extra is not available for this public-inbox
-Return to index
+ require PublicInbox::WwwStream; + PublicInbox::WwwStream::html_oneshot($ctx, 501, \<$extra is not available for this public-inbox +Return to index EOF - [ 501, [ 'Content-Type' => 'text/html; charset=UTF-8' ], [ $msg ] ]; } # /$INBOX/$MESSAGE_ID/t.mbox -> thread as mbox -- cgit v1.2.3-24-ge0c7