From efd8a32ed6618ae89c0827133e3982b383abf8bc Mon Sep 17 00:00:00 2001 From: ed Date: Mon, 28 Oct 2024 03:38:15 +0000 Subject: [PATCH] ui: show switch-to-https on 403s too --- copyparty/httpcli.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/copyparty/httpcli.py b/copyparty/httpcli.py index 4a496ab6..76d17bbb 100644 --- a/copyparty/httpcli.py +++ b/copyparty/httpcli.py @@ -4535,8 +4535,14 @@ class HttpCli(object): t = t.format(self.args.SR) qv = quotep(self.vpaths) + self.ourlq() - in_shr = self.args.shr and self.vpath.startswith(self.args.shr1) - html = self.j2s("splash", this=self, qvpath=qv, in_shr=in_shr, msg=t) + html = self.j2s( + "splash", + this=self, + qvpath=qv, + msg=t, + in_shr=self.args.shr and self.vpath.startswith(self.args.shr1), + ahttps="" if self.is_https else "https://" + self.host + self.req, + ) self.reply(html.encode("utf-8"), status=rc) return True