Comparing version 1.0.3 to 1.0.4
12
mail.js
@@ -58,3 +58,3 @@ // Simple SMTP Email Sender | ||
var body_raw = parts.join("\n\n"); | ||
if (!body_raw.match(/\S/)) return callback( new Error("Cannot locate e-mail body.") ); | ||
if (!body_raw.match(/\S/)) return callback( new Error("Cannot locate e-mail body."), data ); | ||
@@ -73,5 +73,5 @@ // parse headers into key/value pairs | ||
if (!to) return callback( new Error("Missing required header: 'To'") ); | ||
if (!from) return callback( new Error("Missing required header: 'From'") ); | ||
if (!subject) return callback( new Error("Missing required header: 'Subject'") ); | ||
if (!to) return callback( new Error("Missing required header: 'To'"), data ); | ||
if (!from) return callback( new Error("Missing required header: 'From'"), data ); | ||
if (!subject) return callback( new Error("Missing required header: 'Subject'"), data ); | ||
@@ -109,4 +109,6 @@ delete headers['To']; | ||
// send mail | ||
transport.sendMail( opts, callback ); | ||
transport.sendMail( opts, function(err) { | ||
callback( err, data ); | ||
} ); | ||
} | ||
}); |
{ | ||
"name": "pixl-mail", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "A very simple class for sending e-mail via SMTP.", | ||
@@ -5,0 +5,0 @@ "author": "Joseph Huckaby <jhuckaby@gmail.com>", |
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
9674
88