minor template restructuring