We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7033c44 commit b4f878dCopy full SHA for b4f878d
lib/api/api.js
@@ -227,8 +227,10 @@ const api = {
227
if ('key' in request.formData) {
228
return next(null);
229
}
230
- return next(errors.InvalidArgument.customizeDescription('Bucket POST must contain'
231
- + " a field named 'key'. If it is specified, please check the order of the fields."));
+
+ const err = errors.InvalidArgument.customizeDescription('Bucket POST must contain'
232
+ + " a field named 'key'. If it is specified, please check the order of the fields.");
233
+ formDataParser.emit('error', err);
234
});
235
formDataParser.on('finish', () => {
236
// No file field == error
0 commit comments