Fixed deprecated variable names in templates