Use locate

main
Bob Mottram 2019-11-18 10:27:34 +00:00
parent eacef272d3
commit c87713ff79
1 changed files with 6 additions and 6 deletions

View File

@ -2135,10 +2135,10 @@ def createBoxBase(session,baseDir: str,boxname: str, \
postFilename=indexFile.readline() postFilename=indexFile.readline()
if not postFilename: if not postFilename:
break break
postFilename=postFilename.replace('\n','') postUrl=postFilename.replace('\n','').replace('.json','')
fullPostFilename=os.path.join(boxDir, postFilename) fullPostFilename= \
if not os.path.isfile(fullPostFilename): locatePost(baseDir,nickname,domain,postUrl,False)
fullPostFilename=os.path.join(announceCacheDir, postFilename) if fullPostFilename:
postsInBox[postsCtr]=fullPostFilename postsInBox[postsCtr]=fullPostFilename
postsCtr+=1 postsCtr+=1
lookedUpFromIndex=True lookedUpFromIndex=True