diff --git a/content.py b/content.py
index 7b244b541..41ca0a1c8 100644
--- a/content.py
+++ b/content.py
@@ -60,7 +60,6 @@ def addWebLinks(content: str) -> str:
return content
words=content.replace('\n',' --linebreak-- ').split(' ')
- print(str(words))
replaceDict={}
for w in words:
if w.startswith('https://') or \
@@ -78,8 +77,10 @@ def addWebLinks(content: str) -> str:
linkText=w.replace('https://','').replace('http://','').replace('dat://','')
# prevent links from becoming too long
if len(linkText)>40:
- linkText=linkText[:40]
- markup+=''+linkText+''
+ markup+=''+linkText[:40]+''
+ markup+=''+linkText[40:]+''
+ else:
+ markup+=''+linkText+''
replaceDict[w]=markup
for url,markup in replaceDict.items():
content=content.replace(url,markup)