template stucture fix