mirror of https://gitlab.com/bashrc2/epicyon
Remove endings from hashtags
parent
03c234eac9
commit
ab6994329a
|
@ -788,6 +788,12 @@ def addHtmlTags(baseDir: str, httpPrefix: str,
|
||||||
prevWordStr = ''
|
prevWordStr = ''
|
||||||
continue
|
continue
|
||||||
elif firstChar == '#':
|
elif firstChar == '#':
|
||||||
|
# remove any endings from the hashtag
|
||||||
|
hashTagEndings = ('.', ':', ';', '-', '\n')
|
||||||
|
for ending in hashTagEndings:
|
||||||
|
if wordStr.endswith(ending):
|
||||||
|
wordStr = wordStr.replace(ending, '')
|
||||||
|
|
||||||
if _addHashTags(wordStr, httpPrefix, originalDomain,
|
if _addHashTags(wordStr, httpPrefix, originalDomain,
|
||||||
replaceHashTags, hashtags):
|
replaceHashTags, hashtags):
|
||||||
prevWordStr = ''
|
prevWordStr = ''
|
||||||
|
|
Loading…
Reference in New Issue