fix clean text bug

This commit is contained in:
zhangwei13
2025-08-07 16:22:23 +08:00
parent 1bfc94c224
commit dcd3256cc7
+2 -1
View File
@@ -136,7 +136,8 @@ def clean_text(text: str) -> str:
text = text.strip() text = text.strip()
# Replace multiple consecutive whitespace characters with a single space # Replace multiple consecutive whitespace characters with a single space
text = re.sub(r'\s+', ' ', text) if text[:2] == '`$' and text[-2:] == '$`':
text = text[1:-1]
return text return text