#0000002 Template code fixes