Skip to content

Commit 2f00566

Browse files
committed
Fixed Markdown issue.
1 parent 7c35dfb commit 2f00566

File tree

1 file changed

+17
-17
lines changed

1 file changed

+17
-17
lines changed

API.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -519,7 +519,7 @@ server.route({
519519
method: 'GET',
520520
path: '/',
521521
handler: function (request, reply) {
522-
522+
523523
return reply(request.auth.credentials.user);
524524
}
525525
});
@@ -627,7 +627,7 @@ server.route({
627627
config: {
628628
auth: 'default',
629629
handler: function (request, reply) {
630-
630+
631631
return reply(request.auth.credentials.user);
632632
}
633633
}
@@ -659,7 +659,7 @@ server.route({
659659
method: 'GET',
660660
path: '/',
661661
handler: function (request, reply) {
662-
662+
663663
request.server.auth.test('default', request, function (err, credentials) {
664664

665665
if (err) {
@@ -753,7 +753,7 @@ Adds an incoming server connection where:
753753
- `address` - sets the host name or IP address the connection will listen on. If not configured,
754754
defaults to `host` if present, otherwise to all available network interfaces (i.e. `'0.0.0.0'`).
755755
Set to `127.0.0.1` or `localhost` to restrict connection to only those coming from the same
756-
machine.
756+
machine.
757757
- `port` - the TCP port the connection will listen to. Defaults to an ephemeral port (`0`) which
758758
uses an available port when the server is started (and assigned to `server.info.port`). If `port`
759759
is a string containing a '/' character, it is used as a UNIX domain socket path and if it starts
@@ -1448,7 +1448,7 @@ across multiple requests. Registers a cookie definitions where:
14481448
- `'base64'` - string value is encoded using Base64.
14491449
- `'base64json'` - object value is JSON-stringified than encoded using Base64.
14501450
- `'form'` - object value is encoded using the _x-www-form-urlencoded_ method.
1451-
- `'iron'` - Encrypts and sign the value using
1451+
- `'iron'` - Encrypts and sign the value using
14521452
[**iron**](https://github.com/hueniverse/iron).
14531453
- `sign` - an object used to calculate an HMAC for cookie integrity validation. This does not
14541454
provide privacy, only a mean to verify that the cookie value was generated by the server.
@@ -2527,18 +2527,18 @@ config to an object containing one of these keys:
25272527
value is the header content.
25282528
- `onResponse` - a custom function for processing the response from the upstream service
25292529
before sending to the client. Useful for custom error handling of responses from the
2530-
proxied endpoint or other payload manipulation. Function signature is
2530+
proxied endpoint or other payload manipulation. Function signature is
25312531
`function(err, res, request, reply, settings, ttl)` where:
2532-
- `err` - internal or upstream error returned from attempting to contact the upstream
2533-
proxy.
2534-
- `res` - the node response object received from the upstream service. `res` is a
2535-
readable stream (use the [**wreck**](https://github.com/hapijs/wreck) module `read`
2536-
method to easily convert it to a Buffer or string).
2537-
- `request` - is the incoming [request object](#request-object).
2538-
- `reply` - the [reply interface](#reply-interface) function.
2539-
- `settings` - the proxy handler configuration.
2540-
- `ttl` - the upstream TTL in milliseconds if `proxy.ttl` it set to `'upstream'` and
2541-
the upstream response included a valid 'Cache-Control' header with 'max-age'.
2532+
- `err` - internal or upstream error returned from attempting to contact the upstream
2533+
proxy.
2534+
- `res` - the node response object received from the upstream service. `res` is a
2535+
readable stream (use the [**wreck**](https://github.com/hapijs/wreck) module `read`
2536+
method to easily convert it to a Buffer or string).
2537+
- `request` - is the incoming [request object](#request-object).
2538+
- `reply` - the [reply interface](#reply-interface) function.
2539+
- `settings` - the proxy handler configuration.
2540+
- `ttl` - the upstream TTL in milliseconds if `proxy.ttl` it set to `'upstream'` and
2541+
the upstream response included a valid 'Cache-Control' header with 'max-age'.
25422542
- `ttl` - if set to `'upstream'`, applies the upstream response caching policy to the
25432543
response using the `response.ttl()` method (or passed as an argument to the `onResponse`
25442544
method if provided).
@@ -2911,7 +2911,7 @@ where:
29112911
- `result` - an optional response payload.
29122912

29132913
Since an request can only have one response regardless if it is an error or success, the `reply()`
2914-
method can only result in a single response value. This means that passing both an `err` and
2914+
method can only result in a single response value. This means that passing both an `err` and
29152915
`result` will only use the `err`. There is no requirement for either `err` or `result` to be (or
29162916
not) an `Error` object. The framework will simply use the first argument if present, otherwise the
29172917
second. The method supports two arguments to be compatible with the common callback pattern of

0 commit comments

Comments
 (0)