mirror of
https://gerrit.googlesource.com/git-repo
synced 2024-12-21 07:16:21 +00:00
Fix substitution err for schemeless manifest urls
Previously, we used a regex that would only remove a phony string from a url if it existed, but we recently replaced that with a slice. This change goes back to the previous behavior. Change-Id: I8baf527be01c4b49d45b903b31a1cd6315563d5b
This commit is contained in:
parent
403b64edf4
commit
4ccad7554b
@ -90,7 +90,8 @@ class _XmlRemote(object):
|
||||
# and then replacing it with the original when we are done.
|
||||
|
||||
if manifestUrl.find(':') != manifestUrl.find('/') - 1:
|
||||
url = urllib.parse.urljoin('gopher://' + manifestUrl, url)[9:]
|
||||
url = urllib.parse.urljoin('gopher://' + manifestUrl, url)
|
||||
url = re.sub(r'^gopher://', '', url)
|
||||
else:
|
||||
url = urllib.parse.urljoin(manifestUrl, url)
|
||||
return url
|
||||
|
Loading…
Reference in New Issue
Block a user