Skip to content

Commit

Permalink
pass all lambda event data to template so we can send the verify link…
Browse files Browse the repository at this point in the history
… directly from auth app dwyl/auth#62
  • Loading branch information
nelsonic committed May 2, 2020
1 parent 892cb16 commit 322f5bb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/send.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,6 @@ module.exports = function send (event, callback) {
name: event.name || "", // allow email to be sent without name
pixel_url: "https://" + process.env.EMAIL_APP_URL + "/read/" + token
};
return sendemail(template, options, callback);
const merged = {...event, ...options}; // expose all of event to template
return sendemail(template, merged, callback);
};

0 comments on commit 322f5bb

Please sign in to comment.