From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: X-Spam-Status: No, score=-4.0 required=3.0 tests=ALL_TRUSTED,BAYES_00 shortcircuit=no autolearn=ham autolearn_force=no version=3.4.2 Received: from localhost (dcvr.yhbt.net [127.0.0.1]) by dcvr.yhbt.net (Postfix) with ESMTP id 07B191F8C6; Tue, 7 Sep 2021 22:02:04 +0000 (UTC) Date: Tue, 7 Sep 2021 22:02:03 +0000 From: Eric Wong To: meta@public-inbox.org Cc: Konstantin Ryabitsev Subject: [PATCH] news_www: favor ->ALL URL when using ->ALL Message-ID: <20210907220203.GA17787@dcvr> References: <20210907140954.4rlh6pn5fz4ljkxp@meerkat.local> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210907140954.4rlh6pn5fz4ljkxp@meerkat.local> List-Id: This allows us to link to threads spread across multiple inboxes. Reported-by: Konstantin Ryabitsev Link: https://public-inbox.org/meta/20210907140954.4rlh6pn5fz4ljkxp@meerkat.local/ --- lib/PublicInbox/NewsWWW.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/PublicInbox/NewsWWW.pm b/lib/PublicInbox/NewsWWW.pm index abafc4f9..d13731ae 100644 --- a/lib/PublicInbox/NewsWWW.pm +++ b/lib/PublicInbox/NewsWWW.pm @@ -82,7 +82,8 @@ sub call { for (@$xr3) { s/:[0-9]+:$x->{blob}\z// or next; my $ibx = $by_eidx_key->{$_} // next; - my $url = $ibx->base_url or next; + my $url = $ALL->base_url($env) // + $ibx->base_url // next; $url .= mid_escape($mid) . '/'; return redirect(302, $url); }