Template tidy up.