Fixing warning regarding deprecated variable reference in templates.