Correctly escape document information

This commit is contained in:
RunasSudo 2019-12-15 14:08:53 +11:00
parent da6a35b0d6
commit d4fa0ae689
Signed by: RunasSudo
GPG Key ID: 7234E476BF21C61A
2 changed files with 6 additions and 6 deletions

View File

@ -316,7 +316,7 @@ class LaTeXRenderer(mistletoe.latex_renderer.LaTeXRenderer):
return format(template, return format(template,
inner=self.render_inner(token), inner=self.render_inner(token),
packages=self.render_packages(), packages=self.render_packages(),
title=token.title, title=self.render_raw_text(mistletoe.span_token.RawText(token.title)),
author=token.author, author=self.render_raw_text(mistletoe.span_token.RawText(token.author)),
footer=token.footer footer=self.render_raw_text(mistletoe.span_token.RawText(token.footer))
) )

View File

@ -276,9 +276,9 @@ class RTFRenderer(mistletoe.base_renderer.BaseRenderer):
flushright=cm_to_twip(21 - 2 - 2), flushright=cm_to_twip(21 - 2 - 2),
parskip=cm_to_twip(0.35), parskip=cm_to_twip(0.35),
inner=self.render_inner(token), inner=self.render_inner(token),
title=token.title, title=self.render_raw_text(mistletoe.span_token.RawText(token.title)),
author=token.author, author=self.render_raw_text(mistletoe.span_token.RawText(token.author)),
footer=token.footer footer=self.render_raw_text(mistletoe.span_token.RawText(token.footer))
) )
result = [] result = []