Example #1
0
 form.on('close', function(){
   if (done) return;
   try {
     req.body = qs.parse(data, { allowDots: false, allowPrototypes: true });
     req.files = qs.parse(files, { allowDots: false, allowPrototypes: true });
   } catch (err) {
     form.emit('error', err);
     return;
   }
   if (!options.defer) next();
 });
Example #2
0
 form.on('close', function () {
   if (done) return;
   try {
     req.body = qs.parse(data);
     req.files = qs.parse(files);
   } catch (err) {
     form.emit('error', err);
     return;
   }
   if (!options.defer) next();
 });
Example #3
0
 .catch((error) => form.emit('error', error))