diff --git a/app/utils/results.py b/app/utils/results.py index 7b2f5f2fad..1b69d81ced 100644 --- a/app/utils/results.py +++ b/app/utils/results.py @@ -99,7 +99,7 @@ def replace_any_case(element: NavigableString, target_word: str) -> None: else: reg_pattern = fr'\b((?![{{}}<>-]){target_word}(?![{{}}<>-]))\b' - if re.match('.*[@_!#$%^&*()<>?/\|}{~:].*', target_word) or ( + if re.match(r'.*[@_!#$%^&*()<>?/\|}{~:].*', target_word) or ( element.parent and element.parent.name == 'style'): return