Prestaul/jsend — pull request #1 by selfcontained (2014-08-14 16:45:15+00:00)
Title: exposing standalone status functions for greater flexibility

I have a use case where I just need to create proper jsend payloads, but don't need the middleware functionality. With a minor tweak, this exposes the functionality around creating those payloads as standalone functions:

```javascript
var jsend = require('jsend');

var payload = jsend.success(data);

var payload = jsend.fail(data);

var payload = jsend.error(msg);
```

The existing middleware function now just uses those same `success`, `fail`, and `error` functions internally.