From 8f52142116a134b95407d6f9f11d022bc6d9cf8f Mon Sep 17 00:00:00 2001 From: Aaron Heckmann Date: Sat, 30 Jan 2010 23:41:22 -0500 Subject: [PATCH] look for -1 instead of false returned from string.indexOf --- lib/multipart.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/multipart.js b/lib/multipart.js index 826be951ee..dc2a8cea88 100644 --- a/lib/multipart.js +++ b/lib/multipart.js @@ -183,7 +183,7 @@ Part.prototype.write = function(chunk) { var header = this.buffer.substr(0, offset).split(/: ?/); this.headers[header[0].toLowerCase()] = header[1]; this.buffer = this.buffer.substr(offset+2); - } else if (offset === false) { + } else if (offset === -1) { return; } }