fix utf-8 templates error