senchalabs/connect — pull request #828 by breck7 (2013-06-24 21:43:02+00:00)
Title: Added ability provide a filter function

Let's say you didn't want to server a certain folder or type of file that you store in the public folder. This allows you to pass a callback that is just a more general version of the hidden filter.

Example to serve all files in a folder named 'public' except for text files:

```
app.use('/', express.static('public/', { filter: function (filename) { return filename.match(/\.txt/) } }))
```

I'm submitting a complementary patch to Send as well.