cleared up template mess