add missing var declaration in sensor template