Skip to content

Commit 27b6136

Browse files
Merge pull request #36 from dries/master
Add error handlers for parser errors
2 parents b9ee66e + 0713f6f commit 27b6136

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/index.js

+4
Original file line numberDiff line numberDiff line change
@@ -154,10 +154,14 @@ function processMultipart(options, req, res, next) {
154154
req.files[fieldname] = [req.files[fieldname], newFile];
155155
}
156156
});
157+
158+
file.on('error', next);
157159
});
158160

159161
busboy.on('finish', next);
160162

163+
busboy.on('error', next);
164+
161165
req.pipe(busboy);
162166
}
163167

0 commit comments

Comments
 (0)