main
Bob Mottram 2020-04-15 10:23:44 +01:00
parent 0e87344ee7
commit b435af8d76
1 changed files with 3 additions and 1 deletions

View File

@ -498,13 +498,15 @@ def htmlHashtagSearch(nickname: str, domain: str, port: int,
httpPrefix: str, projectVersion: str) -> str: httpPrefix: str, projectVersion: str) -> str:
"""Show a page containing search results for a hashtag """Show a page containing search results for a hashtag
""" """
iconsDir = getIconsDir(baseDir)
if hashtag.startswith('#'): if hashtag.startswith('#'):
hashtag = hashtag[1:] hashtag = hashtag[1:]
hashtagIndexFile = baseDir + '/tags/' + hashtag + '.txt' hashtagIndexFile = baseDir + '/tags/' + hashtag + '.txt'
if not os.path.isfile(hashtagIndexFile): if not os.path.isfile(hashtagIndexFile):
print('WARN: hashtag file not found ' + hashtagIndexFile)
return None return None
iconsDir = getIconsDir(baseDir)
# check that the directory for the nickname exists # check that the directory for the nickname exists
if nickname: if nickname:
if not os.path.isdir(baseDir + '/accounts/' + if not os.path.isdir(baseDir + '/accounts/' +