Skip to content

Commit

Permalink
Merge pull request #3788 from mannypamintuan/documentation-update
Browse files Browse the repository at this point in the history
Documentation Update: `server.events` example in API.md
  • Loading branch information
hueniverse committed May 2, 2018
2 parents 12f3a1d + 16bcc1f commit 3e58865
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions API.md
Original file line number Diff line number Diff line change
Expand Up @@ -791,7 +791,7 @@ signature `function(request)` where:
```js
server.events.on('response', (request) => {

console.log(`Response sent for request: ${request.id}`);
console.log(`Response sent for request: ${request.info.id}`);
});
```

Expand Down Expand Up @@ -3824,7 +3824,7 @@ values:
- a [lifecycle method](#lifecycle-methods) with the signature `async function(request, h, err)`
where:
- `request` - the [request object](#request).
- `h` - the [response toolkit](#tookit-interface).
- `h` - the [response toolkit](#response-toolkit).
- `err` - the error object.

#### Errors
Expand Down Expand Up @@ -4717,8 +4717,7 @@ wrapped response object, use `responses`.
Access: read / write (see limitations below).

The response object when set. The object can be modified but must not be assigned another object.
To replace the response with another from within an [extension point](#server.ext()),
use `reply(response)` to override with a different response. Contains `null` when no response has
To replace the response with another from within an [extension point](#server.ext()), return a new response value. Contains `null` when no response has
been set (e.g. when a request terminates prematurely when the client disconnects).

#### <a name="request.preResponses" /> `request.preResponses`
Expand Down

0 comments on commit 3e58865

Please sign in to comment.