add link cleaning and a test for it

This commit is contained in:
marc.torsoc
2025-05-21 12:08:53 +02:00
parent c4778e770e
commit ca35299dcd
2 changed files with 15 additions and 0 deletions

View File

@@ -100,6 +100,9 @@ class MarkdownTextFilter(BaseTextFilter):
# Restore leading and trailing spaces
filtered_text = re.sub("§", " ", filtered_text)
## Make links more readable
filtered_text = re.sub(r"https?://", "", filtered_text)
return filtered_text
else:
return text