Permalink
Browse files

Fix mustache variable in subject

  • Loading branch information...
jiem committed Nov 29, 2012
1 parent a797ad9 commit 3a5815cdcd86ffd01b0307fe04e12cb53c161390
Showing with 2 additions and 2 deletions.
  1. +2 −2 index.js
View
@@ -77,8 +77,8 @@ function initMustache(email) {
if (email.html)
email.html = email.html.replace(mustacheVarReg, '{{$1}}');
- email.mustacheVars = {};
- match = (email.html || email.text).match(mustacheVarReg);
+ email.mustacheVars = {};
+ match = (email.subject + email.text + email.html).match(mustacheVarReg);
if (match)
for (i = 0; mustacheVar = match[i]; i++)
email.mustacheVars[mustacheVar.substring(2, mustacheVar.length - 2)] = 1;

0 comments on commit 3a5815c

Please sign in to comment.