diff options
author | Eric Wong <e@80x24.org> | 2021-09-02 22:12:59 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-09-02 22:58:21 +0000 |
commit | 9b2c705f92a6baf33684aa0845dc5163ae31016e (patch) | |
tree | 89e794241a3ba223b9276e61f4a207b1f9d60bb7 /lib/PublicInbox/View.pm | |
parent | d369390960722fc56c86319134debe5cd7c0c7f6 (diff) | |
download | public-inbox-9b2c705f92a6baf33684aa0845dc5163ae31016e.tar.gz |
Apparently URLs can be configured relatively for HTTP(S) setups, attempt to support them when linking to cross-posted messages. This also fixes the top-row (mirror/help/color/Atom feed) links in /$INBOX_URL/$EXTMSG_MSGID/T/ (and /t/) URLs. Reported-by: Konstantin Ryabitsev <konstantin@linuxfoundation.org> Link: https://public-inbox.org/meta/20210902191239.cmbxlmjqcsmdzmqp@meerkat.local/
Diffstat (limited to 'lib/PublicInbox/View.pm')
-rw-r--r-- | lib/PublicInbox/View.pm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/PublicInbox/View.pm b/lib/PublicInbox/View.pm index 94ea6148..805e785b 100644 --- a/lib/PublicInbox/View.pm +++ b/lib/PublicInbox/View.pm @@ -432,6 +432,7 @@ sub stream_thread ($$) { # /$INBOX/$MSGID/t/ and /$INBOX/$MSGID/T/ sub thread_html { my ($ctx) = @_; + $ctx->{-upfx} = '../../'; my $mid = $ctx->{mid}; my $ibx = $ctx->{ibx}; my ($nr, $msgs) = $ibx->over->get_thread($mid); @@ -455,7 +456,6 @@ EOF $skel .= " (download: <a\nhref=\"../t.mbox.gz\">mbox.gz</a>"; $skel .= " / follow: <a\nhref=\"../t.atom\">Atom feed</a>)\n"; $skel .= "-- links below jump to the message on this page --\n"; - $ctx->{-upfx} = '../../'; $ctx->{cur_level} = 0; $ctx->{skel} = \$skel; $ctx->{prev_attr} = ''; |