Fix #lines in template.