Remove path from index entries

main2
Bob Mottram 2019-10-20 12:06:12 +01:00
parent a318f299ca
commit 3025922d5c
1 changed files with 2 additions and 0 deletions

View File

@ -1512,6 +1512,8 @@ def inboxUpdateIndex(baseDir: str,handle: str,destinationFilename: str,debug: bo
indexFilename=baseDir+'/accounts/'+handle+'/inbox.index'
if debug:
print('DEBUG: Updating index '+indexFilename)
if '/index/' in destinationFilename:
destinationFilename=destinationFilename.split('/index/')[1]
if os.path.isfile(indexFilename):
with open(indexFilename, 'r+') as indexFile:
content = indexFile.read()