cleanup templates vars