Fix JSONDecodeError when bottle.SimpleTemplate is used

This commit is contained in:
Ivan Kravets
2020-04-27 23:41:36 +03:00
parent c215abb50c
commit 4a251f0ab0

View File

@ -151,7 +151,7 @@ class ProjectGenerator(object):
@staticmethod
def _render_tpl(tpl_path, tpl_vars):
with codecs.open(tpl_path, "r", encoding="utf8") as fp:
return bottle.SimpleTemplate(fp.read()).render(**tpl_vars)
return bottle.template(fp.read(), **tpl_vars)
@staticmethod
def _merge_contents(dst_path, contents):