GetBlimp/filepreviews.js — pull request #5 by jpadilla (2014-08-20 15:44:16+00:00)
Title: Handle different signatures for generate function

This should handle the different scenarios that came to mind when using the generate function.

```javascript
var options = {
format: 'jpg'
}

previews.generate('http://filepreviews.io/', options, function(err, result) {
console.log(result.previewURL);
console.log(result.metadata);
});

previews.generate('http://filepreviews.io/', function(err, result) {
console.log(result.previewURL);
console.log(result.metadata);
});

previews.generate('http://filepreviews.io/');

previews.generate('http://filepreviews.io/', options);
```