Added a template filter to do required escaping in iCalendar pages.
- Legacy-Id: 6533
This commit is contained in:
parent
04e3a48ae0
commit
bf75cd1bef
|
@ -490,4 +490,8 @@ def plural(text, list, arg=u's'):
|
|||
return text
|
||||
else:
|
||||
return text + pluralize(len(list), arg)
|
||||
|
||||
|
||||
@register.filter
|
||||
def ics_esc(text):
|
||||
text = re.sub(r"([\n,;\\])", r"\\\1", text)
|
||||
return text
|
||||
|
|
Loading…
Reference in a new issue