Fix bug in escape_curly_brackets (#6909)

This commit is contained in:
Francisco Couzo 2019-10-04 17:50:19 -03:00 committed by Ryan P Kilby
parent b4db2dfacf
commit 37dcd55370

View File

@ -38,9 +38,7 @@ def escape_curly_brackets(url_path):
"""
Double brackets in regex of url_path for escape string formatting
"""
if ('{' and '}') in url_path:
url_path = url_path.replace('{', '{{').replace('}', '}}')
return url_path
return url_path.replace('{', '{{').replace('}', '}}')
def flatten(list_of_lists):