From 56d3bcf515ba1d180a32cf511a2bcc5a7378f964 Mon Sep 17 00:00:00 2001 From: ed Date: Mon, 14 Jul 2025 03:48:27 +0200 Subject: [PATCH] rss: fix --rp-loc; some rss links were malformed when combined with rp-loc --- copyparty/httpcli.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/copyparty/httpcli.py b/copyparty/httpcli.py index 1a9ab91d..f47c8fe8 100644 --- a/copyparty/httpcli.py +++ b/copyparty/httpcli.py @@ -1374,12 +1374,13 @@ class HttpCli(object): title = self.uparam.get("title") or self.vpath.split("/")[-1] etitle = html_escape(title, True, True) - baseurl = "%s://%s%s" % ( + baseurl = "%s://%s/" % ( "https" if self.is_https else "http", self.host, - self.args.SRS, ) - feed = "%s%s" % (baseurl, self.req[1:]) + feed = baseurl + self.req[1:] + if self.is_vproxied: + baseurl += self.args.RS efeed = html_escape(feed, True, True) edirlink = efeed.split("?")[0] + q_pw @@ -1392,7 +1393,7 @@ class HttpCli(object): \t\t%s \t\t \t\t%s -\t\tcopyparty-1 +\t\tcopyparty-2 """ % (efeed, etitle, edirlink) ]