hapijs/hapi — pull request #2288 by yury (2014-12-15 14:00:07+00:00)
Title: Add automatic reply call if handler return promise

Hi,

Thank you for adding promises support to Hapi. What about taking next step, and check return value from handler?

So instead of this:

```js
handler: function(request, reply) {
var promise = this.db.Comment.createAsync(request.payload)
.then(function(comment) {
return { comment: comment };
});

reply(promise);
}
```

we can write this:

```js
handler: function(request, reply) {
return this.db.Comment.createAsync(request.payload)
.then(function(comment) {
return { comment: comment };
});
}
```