Don't remove radicle links

main
Bob Mottram 2020-12-06 10:18:41 +00:00
parent bcbcfed886
commit 9e483bdacf
2 changed files with 7 additions and 0 deletions

View File

@ -651,6 +651,8 @@ def removeLongWords(content: str, maxWordLength: int,
continue
elif 'dat:' in wordStr:
continue
elif 'rad:' in wordStr:
continue
elif 'hyper:' in wordStr:
continue
elif 'briar:' in wordStr:

View File

@ -1747,6 +1747,11 @@ def testWebLinks():
'<p>Test1 test2 '
'#YetAnotherExcessivelyLongwindedAndBorin\ngHashtag</p>')
exampleText = \
"<p>Don't remove a p2p link rad:git:hwd1yrerc3mcgn8ga9rho3dqi4w33nep7kxmqezss4topyfgmexihp33xcw</p>"
resultText = removeLongWords(addWebLinks(exampleText), 40, [])
assert resultText == exampleText
def testAddEmoji():
print('testAddEmoji')