Fix bug when quotes are present in template subjects