fullscale/elastic.js — pull request #49 by surjikal (2013-12-15 18:24:00+00:00)
Title: Node promise support

Added promise support to the node client, without sacrificing backwards compatibility.

```coffeescript
ejs.Request()
.indices("tweets")
.types("tweet")
.query(ejs.TermQuery("user","kimchi"))
.doSearch()
.then (results) ->
console.log(results)
```

Note that you cannot use both callbacks and deferreds; If a callback is passed in, it will be used instead of the deferred's callback.