use wrong variable in template