summary refs log tree commit diff
path: root/scripts
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2023-04-15 01:53:43 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2023-04-15 01:53:43 +0200
commita6c41119ac43d0396052e13a32a0c5800e93745a (patch)
tree60ef548dced5167e63896ad631cad46aa58bc69b /scripts
parentTry to fix the flat-manager script for flat-manager behind reverse proxies (diff)
downloadnheko-a6c41119ac43d0396052e13a32a0c5800e93745a.tar.xz
yarl.URL.scheme is not writable
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/flat-manager-client4
1 files changed, 1 insertions, 3 deletions
diff --git a/scripts/flat-manager-client b/scripts/flat-manager-client
index 581ee268..ec9cd2e4 100755
--- a/scripts/flat-manager-client
+++ b/scripts/flat-manager-client
@@ -570,9 +570,7 @@ def should_skip_delta(id, globs):
 def keep_host(location, original):
     loc_url = URL(location)
     org_url = URL(original)
-    loc_url.scheme = org_url.scheme
-    loc_url.authority = org_url.authority
-    return str(loc_url)
+    return str(loc_url.with_scheme(org_url.scheme).with_host(org_url.host).with_port(org_url.port))
 
 def build_url_to_api(build_url):
     parts = urlparse(build_url)