Minor update to template encoding.