Fix bad variable in template