lib/param-parser.js
function parseFormDataParams (req, res, next) {
  getParams(req).forEach((param) => {
    if (param.in === "formData") {
      util.debug('    Parsing the "%s" form-data parameter', param.name);

      if (param.type === "file") {
        // Validate the file (min/max size, etc.)
        req.files[param.name] = parseParameter(param, req.files[param.name], param);
      }
      else {
        // Parse the body parameter
        req.body[param.name] = parseParameter(param, req.body[param.name], param);
      }
    }
  });

  next();
}
function parseFormDataParams (req, res, next) {
  getParams(req).forEach((param) => {
    if (param.in === "formData") {
      util.debug('    Parsing the "%s" form-data parameter', param.name);

      if (param.type === "file") {
        // Validate the file (min/max size, etc.)
        req.files[param.name] = parseParameter(param, req.files[param.name], param);
      }
      else {
        // Parse the body parameter
        req.body[param.name] = parseParameter(param, req.body[param.name], param);
      }
    }
  });

  next();
}
function parseFormDataParams ( req , res , next ) { getParams ( req ) . forEach ( ( param ) => { if ( param . in === "formData" ) { util . debug ( '    Parsing the "%s" form-data parameter' , param . name ) ; if ( param . type === "file" ) { // Validate the file (min/max size, etc.) req . files [ param . name ] = parseParameter ( param , req . files [ param . name ] , param ) ; } else { // Parse the body parameter req . body [ param . name ] = parseParameter ( param , req . body [ param . name ] , param ) ; } } } ) ; next ( ) ; }
Parses all Swagger parameters in the form data.
Parses all Swagger parameters in the form data .