Return text instead of an empty string in func_rreplace in case of error

This commit is contained in:
Antonio Larrosa
2018-10-10 13:27:46 +02:00
parent 08ff10efd3
commit 1bcc43b288

View File

@@ -445,7 +445,7 @@ def func_rreplace(parser, text, old, new):
try:
return re.sub(old, new, text)
except re.error:
return ""
return text
def func_rsearch(parser, text, pattern):