more template fixes