awsm-mailer
Advanced tools
Comparing version 1.3.5 to 1.3.6
@@ -9,2 +9,3 @@ 'use strict'; | ||
var TEMPLATES_DIR = '../../../aws_modules/awsm-mailer/mailer/templates/'; | ||
var emailRegex = /^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i; | ||
@@ -24,2 +25,6 @@ module.exports.send = function(event) { | ||
if (!emailRegex.test(event.from) || !emailRegex.test(event.to)) { | ||
return cb(new Error('Please provide valid email addresses.')); | ||
} | ||
var templateDir = path.join(__dirname, TEMPLATES_DIR, event.template); | ||
@@ -26,0 +31,0 @@ var template = new EmailTemplate(templateDir); |
{ | ||
"name": "awsm-mailer", | ||
"version": "1.3.5", | ||
"version": "1.3.6", | ||
"description": "AWSM package for sending emails.", | ||
@@ -5,0 +5,0 @@ "main": "lib/mailer.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
13992
173