needs mutable copy for MGTemplateEngine