Skip to content

Commit

Permalink
[docs]:fixed linting issue
Browse files Browse the repository at this point in the history
  • Loading branch information
grjan7 committed Mar 29, 2024
1 parent c4da371 commit 81c9c7a
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ Passes the quite extensive Autobahn test suite: [server][server-report],
[client][client-report].

**Note**: This module does not work in the browser. The client in the docs is a
reference to a backend with the role of a client in the WebSocket
communication. Browser clients must use the native
reference to a backend with the role of a client in the WebSocket communication.
Browser clients must use the native
[`WebSocket`](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket)
object. To make the same code work seamlessly on Node.js and the browser, you
can use one of the many wrappers available on npm, like
Expand Down Expand Up @@ -451,8 +451,8 @@ wss.on('connection', function connection(ws, req) {

### How to detect and close broken connections?

Sometimes, the link between the server and the client can be interrupted in a way
that keeps both the server and the client unaware of the broken state of the
Sometimes, the link between the server and the client can be interrupted in a
way that keeps both the server and the client unaware of the broken state of the
connection (e.g. when pulling the cord).

In these cases, ping messages can be used as a means to verify that the remote
Expand Down
8 changes: 4 additions & 4 deletions SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ following methods:
SHA1 of their latest commit in the project.
- Create a GitHub issue stating contact details and the severity of the issue.

Once we have acknowledged receipt of your report and confirmed the bug ourselves,
we will work with you to fix the vulnerability and publicly acknowledge your
responsible disclosure, if you wish. In addition to that, we will create and
publish a security advisory to
Once we have acknowledged receipt of your report and confirmed the bug
ourselves, we will work with you to fix the vulnerability and publicly
acknowledge your responsible disclosure, if you wish. In addition to that, we
will create and publish a security advisory to
[GitHub Security Advisories](https://github.com/websockets/ws/security/advisories?state=published).

## History
Expand Down
12 changes: 6 additions & 6 deletions doc/ws.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,8 @@ to share a single HTTP/S server between multiple WebSocket servers.
> authentication in the `'upgrade'` event of the HTTP server. See examples for
> more details.
If `verifyClient` is not set, then the handshake is automatically accepted. If it
has a single parameter, then `ws` will invoke it with the following argument:
If `verifyClient` is not set, then the handshake is automatically accepted. If
it has a single parameter, then `ws` will invoke it with the following argument:

- `info` {Object}
- `origin` {String} The value in the Origin header indicated by the client.
Expand All @@ -124,8 +124,8 @@ has a single parameter, then `ws` will invoke it with the following argument:
The return value (`Boolean`) of the function determines whether or not to accept
the handshake.

If `verifyClient` has two parameters, then `ws` will invoke it with the following
arguments:
If `verifyClient` has two parameters, then `ws` will invoke it with the
following arguments:

- `info` {Object} Same as above.
- `cb` {Function} A callback that must be called by the user upon inspection of
Expand All @@ -135,8 +135,8 @@ arguments:
error status code to be sent to the client.
- `name` {String} When `result` is `false`, this field determines the HTTP
reason phrase.
- `headers` {Object} When `result` is `false`, this field determines additional
HTTP headers to be sent to the client. For example,
- `headers` {Object} When `result` is `false`, this field determines
additional HTTP headers to be sent to the client. For example,
`{ 'Retry-After': 120 }`.

`handleProtocols` takes two arguments:
Expand Down

0 comments on commit 81c9c7a

Please sign in to comment.