summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/sendgrid.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sendgrid.js b/lib/sendgrid.js
index 3320b36..15fee86 100644
--- a/lib/sendgrid.js
+++ b/lib/sendgrid.js
@@ -116,7 +116,7 @@ SendGrid.prototype.smtp = function(email, callback) {
function send_smtp() {
smtpTransport.sendMail(email.toSmtpFormat(), function(err, response) {
smtpTransport.close();
- if(err) { return cb(error.data, null);}
+ if(err) { return cb(err.data, null);}
return cb(null, {'message': 'success'});
});