mirror of https://gitlab.com/bashrc2/epicyon
Only quote tags
parent
bdda8c9bf4
commit
7c270019b0
|
@ -716,8 +716,8 @@ class PubServer(BaseHTTPRequestHandler):
|
|||
def _quotedRedirect(self, redirect: str) -> str:
|
||||
"""URL encodes any non-ascii characters for url redirects
|
||||
"""
|
||||
if '/' not in redirect:
|
||||
return urllib.parse.quote_plus(redirect)
|
||||
if '/tags/' not in redirect:
|
||||
return redirect
|
||||
lastStr = redirect.split('/')[-1]
|
||||
return redirect.replace('/' + lastStr, '/' +
|
||||
urllib.parse.quote_plus(lastStr))
|
||||
|
|
Loading…
Reference in New Issue