Update depracated syntax in templates.