Check that tag file exists

main
Bob Mottram 2019-11-27 09:51:59 +00:00
parent 2f66f72d3c
commit 22360c908a
1 changed files with 2 additions and 0 deletions

View File

@ -661,6 +661,8 @@ def removeTagsForNickname(baseDir: str,nickname: str,domain: str,port: int) -> N
if not filename.endswith(".txt"):
continue
tagFilename=os.path.join(baseDir+'/accounts/',filename)
if not os.path.isfile(tagFilename):
continue
if matchStr not in open(tagFilename).read():
continue
with open(tagFilename, "r") as f: