summaryrefslogtreecommitdiffstats
path: root/lib/sendgrid.js
diff options
context:
space:
mode:
authorscottmotte <scott@scottmotte.com>2013-07-22 20:49:12 +0000
committerscottmotte <scott@scottmotte.com>2013-07-22 20:49:12 +0000
commit6fbd4d430d77e6043936c0c4c4061f8ddd93105e (patch)
tree663b31e36be4870c2cc3e089487d405e2954b763 /lib/sendgrid.js
parent511b883dfb9e5f46f2521ff8887020c5caff4c34 (diff)
downloadsendgrid-nodejs-6fbd4d430d77e6043936c0c4c4061f8ddd93105e.zip
sendgrid-nodejs-6fbd4d430d77e6043936c0c4c4061f8ddd93105e.tar.gz
sendgrid-nodejs-6fbd4d430d77e6043936c0c4c4061f8ddd93105e.tar.bz2
Check for value
Diffstat (limited to 'lib/sendgrid.js')
-rw-r--r--lib/sendgrid.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sendgrid.js b/lib/sendgrid.js
index 87f898d..2c1ab23 100644
--- a/lib/sendgrid.js
+++ b/lib/sendgrid.js
@@ -74,7 +74,7 @@ SendGrid.prototype.web = function(email, callback) {
var reqForm = req.form();
for (var field in form) {
var value = form[field];
- if (value.filename) {
+ if (value && value.filename) {
if (value.cid) {
reqForm.append("content["+value.filename+"]", value.cid);
}