Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
connect/express middleware to automatically remove temporary uploaded files
JavaScript
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
lib
test
README.md
package.json

README.md

Overview

This package is a middleware for connect/express to remove potentially uploaded files after each request.

The bodyParser/multipart middleware is great to handle incoming requests and file uploads, but you may be getting files without even knowing it on routes where you don't expect them, thus filling the disk progressively.

This middleware enforces their deletion after the response is done.

Usage

var connect = require('connect')
  , cleaner = require('connect-fileupload-cleaner')
connect()
  .use(connect.bodyParser())
  .use(cleaner())
  [...]
Something went wrong with that request. Please try again.