Tightened up code in Template._render().
* Used re.split() instead of re.search() to avoid string slicing. * Used "".join() once instead of concatenating strings. * Removed the need for repeating logic on loop exit (i.e. an additional application of self._render_tags(template) and output += ...).
Showing
Please
register
or
sign in
to comment