Skip to content

Commit

Permalink
Nit fix for mail merge googleworkspace#163
Browse files Browse the repository at this point in the history
  • Loading branch information
mhawksey committed Feb 12, 2021
1 parent 363060c commit fe210f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mail-merge/src/Code.js
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ function sendEmails(subjectLine, sheet=SpreadsheetApp.getActiveSheet()) {

// token replacement
template_string = template_string.replace(/{{[^{}]+}}/g, key => {
return escapeData_(data[key.replace(/[{}]+/g, "")] || "");
return escapeData_(data[key.replace(/[{}]+/g, "")]) || "";
});
return JSON.parse(template_string);
}
Expand Down

0 comments on commit fe210f5

Please sign in to comment.