fixed a bug where templatized emails were not being parsed properly.