Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

multer

Package Overview
Dependencies
Maintainers
1
Versions
46
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

multer - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

6

index.js

@@ -12,2 +12,3 @@ var os = require('os');

options = options || {};
options.includeEmptyFields = options.includeEmptyFields || false;

@@ -56,4 +57,5 @@ // specify the destination directory, else, the uploads will be moved to the temporary dir of the system

// don't attach to the body object, if there is no value
if (!val) return;
// if includeEmptyFields is false and there is no value then don't
// attach the fields to req.body
if (!options.includeEmptyFields && !val) return;

@@ -60,0 +62,0 @@ if (req.body.hasOwnProperty(fieldname) && val) {

{
"name": "multer",
"version": "0.1.2",
"version": "0.1.3",
"description": "Connect middleware for handling multipart/form-data",

@@ -28,13 +28,13 @@ "main": "index.js",

"dependencies": {
"busboy": "^0.2.6",
"busboy": "^0.2.7",
"mkdirp": "~0.3.5",
"qs": "^0.6.6",
"busboy": "^0.2.7"
"qs": "^0.6.6"
},
"devDependencies": {
"connect": "*",
"chai": "^1.9.1",
"co": "^3.0.6",
"express": "*",
"mocha": "*",
"should": "*",
"supertest": "*",
"express": "*"
"rimraf": "^2.2.8",
"supertest": "^0.13.0"
},

@@ -41,0 +41,0 @@ "author": {

@@ -56,2 +56,3 @@ # Multer [![Build Status](https://travis-ci.org/expressjs/multer.svg?branch=master)](https://travis-ci.org/expressjs/multer) [![NPM version](https://badge.fury.io/js/multer.svg)](https://badge.fury.io/js/multer)

* `limits`
* `includeEmptyFields`
* `rename(fieldname, filename)`

@@ -64,2 +65,3 @@ * `onFileUploadStart(file)`

* `onError()`
* `onFileSizeLimit(file)`
* `onFilesLimit()`

@@ -112,2 +114,10 @@ * `onFieldsLimit()`

### includeEmptyFields
A Boolean value to specify whether empty submitted values should be processed and applied to `req.body`; defaults to `false`;
```js
includeEmptyFields: true
```
### rename(fieldname, filename)

@@ -114,0 +124,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc