Replace +

main2
Bob Mottram 2019-11-03 10:20:30 +00:00
parent f2d652708e
commit 1f644e2812
2 changed files with 2 additions and 2 deletions

View File

@ -3474,7 +3474,7 @@ class PubServer(BaseHTTPRequestHandler):
removeShareConfirmParams=self.rfile.read(length).decode('utf-8')
if '&submitYes=' in removeShareConfirmParams:
removeShareConfirmParams= \
removeShareConfirmParams.replace('%20',' ').replace('%40','@').replace('%3A',':').replace('%2F','/').replace('%23','#').strip()
removeShareConfirmParams.replace('%20',' ').replace('%40','@').replace('%3A',':').replace('%2F','/').replace('%23','#').replace('+',' ').strip()
shareActor=removeShareConfirmParams.split('actor=')[1]
if '&' in shareActor:
shareActor=shareActor.split('&')[0]

View File

@ -26,7 +26,7 @@ def getValidSharedItemID(displayName: str) -> str:
"""Removes any invalid characters from the display name to
produce an item ID
"""
return displayName.replace(' ','').replace('/','-').replace('\\','-').replace('.','_').replace('?','-').replace('\n','').replace("","'")
return displayName.replace(' ','').replace('+','-').replace('/','-').replace('\\','-').replace('.','_').replace('?','-').replace('\n','').replace("","'").replace('&','-')
def removeShare(baseDir: str,nickname: str,domain: str, \
displayName: str) -> None: