From aa9badf916b39c00e015777b196b8cd154e4ae38 Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Sat, 20 Jun 2020 16:46:33 -0700 Subject: [PATCH] doc: use a single space between sentences We mostly have a single space between the punctuation that ends a sentence and the start of the next sentence. Change instances with two spaces to one. PR-URL: https://github.com/nodejs/node/pull/33995 Reviewed-By: Matheus Marchini Reviewed-By: James M Snell Reviewed-By: Trivikram Kamat --- doc/api/buffer.md | 2 +- doc/api/child_process.md | 6 +++--- doc/api/crypto.md | 2 +- doc/api/fs.md | 6 +++--- doc/api/modules.md | 14 +++++++------- doc/api/n-api.md | 2 +- doc/api/net.md | 2 +- doc/api/process.md | 2 +- doc/api/readline.md | 6 +++--- doc/api/stream.md | 2 +- doc/api/tls.md | 20 ++++++++++---------- doc/api/util.md | 2 +- 12 files changed, 33 insertions(+), 33 deletions(-) diff --git a/doc/api/buffer.md b/doc/api/buffer.md index 675a5981745975..9f0b7a391688d9 100644 --- a/doc/api/buffer.md +++ b/doc/api/buffer.md @@ -2700,7 +2700,7 @@ it allows injection of numbers where a naively written application that does not validate its input sufficiently might expect to always receive a string. Before Node.js 8.0.0, the 100 byte buffer might contain arbitrary pre-existing in-memory data, so may be used to expose in-memory -secrets to a remote attacker. Since Node.js 8.0.0, exposure of memory cannot +secrets to a remote attacker. Since Node.js 8.0.0, exposure of memory cannot occur because the data is zero-filled. However, other attacks are still possible, such as causing very large buffers to be allocated by the server, leading to performance degradation or crashing on memory exhaustion. diff --git a/doc/api/child_process.md b/doc/api/child_process.md index e272c7004c1e2d..f09768573e3142 100644 --- a/doc/api/child_process.md +++ b/doc/api/child_process.md @@ -347,7 +347,7 @@ changes: * `detached` {boolean} Prepare child to run independently of its parent process. Specific behavior depends on the platform, see [`options.detached`][]). - * `env` {Object} Environment key-value pairs. **Default:** `process.env`. + * `env` {Object} Environment key-value pairs. **Default:** `process.env`. * `execPath` {string} Executable used to create the child process. * `execArgv` {string[]} List of string arguments passed to the executable. **Default:** `process.execArgv`. @@ -735,7 +735,7 @@ changes: * `stdio` {string|Array} Child's stdio configuration. `stderr` by default will be output to the parent process' stderr unless `stdio` is specified. **Default:** `'pipe'`. - * `env` {Object} Environment key-value pairs. **Default:** `process.env`. + * `env` {Object} Environment key-value pairs. **Default:** `process.env`. * `uid` {number} Sets the user identity of the process (see setuid(2)). * `gid` {number} Sets the group identity of the process (see setgid(2)). * `timeout` {number} In milliseconds the maximum amount of time the process @@ -865,7 +865,7 @@ changes: * `argv0` {string} Explicitly set the value of `argv[0]` sent to the child process. This will be set to `command` if not specified. * `stdio` {string|Array} Child's stdio configuration. - * `env` {Object} Environment key-value pairs. **Default:** `process.env`. + * `env` {Object} Environment key-value pairs. **Default:** `process.env`. * `uid` {number} Sets the user identity of the process (see setuid(2)). * `gid` {number} Sets the group identity of the process (see setgid(2)). * `timeout` {number} In milliseconds the maximum amount of time the process diff --git a/doc/api/crypto.md b/doc/api/crypto.md index c91ebd55e42789..3076bdaa5e5028 100644 --- a/doc/api/crypto.md +++ b/doc/api/crypto.md @@ -2060,7 +2060,7 @@ added: v0.1.92 * `options` {Object} [`stream.Writable` options][] * Returns: {Sign} -Creates and returns a `Sign` object that uses the given `algorithm`. Use +Creates and returns a `Sign` object that uses the given `algorithm`. Use [`crypto.getHashes()`][] to obtain the names of the available digest algorithms. Optional `options` argument controls the `stream.Writable` behavior. diff --git a/doc/api/fs.md b/doc/api/fs.md index 53e9caa498afc7..f477138bbdc01c 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -3594,14 +3594,14 @@ changes: * `err` {Error} Asynchronous symlink(2) which creates the link called `path` pointing to -`target`. No arguments other than a possible exception are given to the +`target`. No arguments other than a possible exception are given to the completion callback. The `type` argument is only available on Windows and ignored on other platforms. It can be set to `'dir'`, `'file'`, or `'junction'`. If the `type` argument is not set, Node.js will autodetect `target` type and use `'file'` or `'dir'`. If the `target` does not exist, `'file'` will be used. Windows junction points -require the destination path to be absolute. When using `'junction'`, the +require the destination path to be absolute. When using `'junction'`, the `target` argument will automatically be normalized to absolute path. Relative targets are relative to the link’s parent directory. @@ -4200,7 +4200,7 @@ before and/or after the newly written data. For example, if `fs.writeFile()` is called twice in a row, first to write the string `'Hello'`, then to write the string `', World'`, the file would contain `'Hello, World'`, and might contain some of the file's original data (depending -on the size of the original file, and the position of the file descriptor). If +on the size of the original file, and the position of the file descriptor). If a file name had been used instead of a descriptor, the file would be guaranteed to contain only `', World'`. diff --git a/doc/api/modules.md b/doc/api/modules.md index 2517c2132102f0..7cb5de8c4589e2 100644 --- a/doc/api/modules.md +++ b/doc/api/modules.md @@ -165,15 +165,15 @@ require(X) from module at path Y 6. THROW "not found" LOAD_AS_FILE(X) -1. If X is a file, load X as its file extension format. STOP -2. If X.js is a file, load X.js as JavaScript text. STOP -3. If X.json is a file, parse X.json to a JavaScript Object. STOP -4. If X.node is a file, load X.node as binary addon. STOP +1. If X is a file, load X as its file extension format. STOP +2. If X.js is a file, load X.js as JavaScript text. STOP +3. If X.json is a file, parse X.json to a JavaScript Object. STOP +4. If X.node is a file, load X.node as binary addon. STOP LOAD_INDEX(X) -1. If X/index.js is a file, load X/index.js as JavaScript text. STOP +1. If X/index.js is a file, load X/index.js as JavaScript text. STOP 2. If X/index.json is a file, parse X/index.json to a JavaScript object. STOP -3. If X/index.node is a file, load X/index.node as binary addon. STOP +3. If X/index.node is a file, load X/index.node as binary addon. STOP LOAD_AS_DIRECTORY(X) 1. If X/package.json is a file, @@ -234,7 +234,7 @@ LOAD_PACKAGE_EXPORTS(DIR, X) a. LOAD_AS_FILE(RESOLVED) b. LOAD_AS_DIRECTORY(RESOLVED) 12. Otherwise - a. If RESOLVED is a file, load it as its file extension format. STOP + a. If RESOLVED is a file, load it as its file extension format. STOP 13. Throw "not found" ``` diff --git a/doc/api/n-api.md b/doc/api/n-api.md index f8ae7f00d8922b..9a8103ce585ef5 100644 --- a/doc/api/n-api.md +++ b/doc/api/n-api.md @@ -646,7 +646,7 @@ typedef void (*napi_async_execute_callback)(napi_env env, void* data); Implementations of this function must avoid making N-API calls that execute JavaScript or interact with -JavaScript objects. N-API +JavaScript objects. N-API calls should be in the `napi_async_complete_callback` instead. Do not use the `napi_env` parameter as it will likely result in execution of JavaScript. diff --git a/doc/api/net.md b/doc/api/net.md index b2d60d1ede6456..2b427b3de77139 100644 --- a/doc/api/net.md +++ b/doc/api/net.md @@ -721,7 +721,7 @@ added: v6.1.0 If `true`, [`socket.connect(options[, connectListener])`][`socket.connect(options)`] was called and has not yet finished. It will stay `true` until the socket becomes -connected, then it is set to `false` and the `'connect'` event is emitted. Note +connected, then it is set to `false` and the `'connect'` event is emitted. Note that the [`socket.connect(options[, connectListener])`][`socket.connect(options)`] callback is a listener for the `'connect'` event. diff --git a/doc/api/process.md b/doc/api/process.md index 53c3ac9aaca4c8..2fb0b77f7df702 100644 --- a/doc/api/process.md +++ b/doc/api/process.md @@ -554,7 +554,7 @@ environment variable. `process.allowedNodeEnvironmentFlags` extends `Set`, but overrides `Set.prototype.has` to recognize several different possible flag -representations. `process.allowedNodeEnvironmentFlags.has()` will +representations. `process.allowedNodeEnvironmentFlags.has()` will return `true` in the following cases: * Flags may omit leading single (`-`) or double (`--`) dashes; e.g., diff --git a/doc/api/readline.md b/doc/api/readline.md index 8cbaf362d5dc03..c3b79d4646709d 100644 --- a/doc/api/readline.md +++ b/doc/api/readline.md @@ -361,7 +361,7 @@ The current input data being processed by node. This can be used when collecting input from a TTY stream to retrieve the current value that has been processed thus far, prior to the `line` event -being emitted. Once the `line` event has been emitted, this property will +being emitted. Once the `line` event has been emitted, this property will be an empty string. Be aware that modifying the value during the instance runtime may have @@ -395,7 +395,7 @@ added: v0.1.98 The cursor position relative to `rl.line`. This will track where the current cursor lands in the input string, when -reading input from a TTY stream. The position of cursor determines the +reading input from a TTY stream. The position of cursor determines the portion of the input string that will be modified as input is processed, as well as the column where the terminal caret will be rendered. @@ -409,7 +409,7 @@ added: v12.16.0 * `cols` {number} the screen column the cursor currently lands on Returns the real position of the cursor in relation to the input -prompt + string. Long input (wrapping) strings, as well as multiple +prompt + string. Long input (wrapping) strings, as well as multiple line prompts are included in the calculations. ## `readline.clearLine(stream, dir[, callback])` diff --git a/doc/api/stream.md b/doc/api/stream.md index 81e32f607fac79..b8c864c7913cd0 100644 --- a/doc/api/stream.md +++ b/doc/api/stream.md @@ -1761,7 +1761,7 @@ changes: specified in the [`stream.write()`][stream-write] call) before passing them to [`stream._write()`][stream-_write]. Other types of data are not converted (i.e. `Buffer`s are not decoded into `string`s). Setting to - false will prevent `string`s from being converted. **Default:** `true`. + false will prevent `string`s from being converted. **Default:** `true`. * `defaultEncoding` {string} The default encoding that is used when no encoding is specified as an argument to [`stream.write()`][stream-write]. **Default:** `'utf8'`. diff --git a/doc/api/tls.md b/doc/api/tls.md index 128da2c10b377d..41f99c91c852b0 100644 --- a/doc/api/tls.md +++ b/doc/api/tls.md @@ -325,9 +325,9 @@ in [`tls.createServer()`][], [`tls.connect()`][], and when creating new The ciphers list can contain a mixture of TLSv1.3 cipher suite names, the ones that start with `'TLS_'`, and specifications for TLSv1.2 and below cipher -suites. The TLSv1.2 ciphers support a legacy specification format, consult +suites. The TLSv1.2 ciphers support a legacy specification format, consult the OpenSSL [cipher list format][] documentation for details, but those -specifications do *not* apply to TLSv1.3 ciphers. The TLSv1.3 suites can only +specifications do *not* apply to TLSv1.3 ciphers. The TLSv1.3 suites can only be enabled by including their full name in the cipher list. They cannot, for example, be enabled or disabled by using the legacy TLSv1.2 `'EECDH'` or `'!EECDH'` specification. @@ -768,12 +768,12 @@ On the client, the `session` can be provided to the `session` option of See [Session Resumption][] for more information. For TLSv1.2 and below, [`tls.TLSSocket.getSession()`][] can be called once -the handshake is complete. For TLSv1.3, only ticket-based resumption is allowed +the handshake is complete. For TLSv1.3, only ticket-based resumption is allowed by the protocol, multiple tickets are sent, and the tickets aren't sent until after the handshake completes. So it is necessary to wait for the -`'session'` event to get a resumable session. Applications +`'session'` event to get a resumable session. Applications should use the `'session'` event instead of `getSession()` to ensure -they will work for all TLS versions. Applications that only expect to +they will work for all TLS versions. Applications that only expect to get or use one session should listen for this event only once: ```js @@ -1610,11 +1610,11 @@ changes: [OpenSSL Options][]. * `secureProtocol` {string} Legacy mechanism to select the TLS protocol version to use, it does not support independent control of the minimum and - maximum version, and does not support limiting the protocol to TLSv1.3. Use - `minVersion` and `maxVersion` instead. The possible values are listed as - [SSL_METHODS][], use the function names as strings. For example, use + maximum version, and does not support limiting the protocol to TLSv1.3. Use + `minVersion` and `maxVersion` instead. The possible values are listed as + [SSL_METHODS][], use the function names as strings. For example, use `'TLSv1_1_method'` to force TLS version 1.1, or `'TLS_method'` to allow any - TLS protocol version up to TLSv1.3. It is not recommended to use TLS + TLS protocol version up to TLSv1.3. It is not recommended to use TLS versions less than 1.2, but it may be required for interoperability. **Default:** none, see `minVersion`. * `sessionIdContext` {string} Opaque identifier used by servers to ensure @@ -1812,7 +1812,7 @@ added: v11.4.0 [`tls.createSecureContext()`][]. It can be assigned any of the supported TLS protocol versions, `'TLSv1.3'`, `'TLSv1.2'`, `'TLSv1.1'`, or `'TLSv1'`. **Default:** `'TLSv1.3'`, unless changed using CLI options. Using - `--tls-max-v1.2` sets the default to `'TLSv1.2'`. Using `--tls-max-v1.3` sets + `--tls-max-v1.2` sets the default to `'TLSv1.2'`. Using `--tls-max-v1.3` sets the default to `'TLSv1.3'`. If multiple of the options are provided, the highest maximum is used. diff --git a/doc/api/util.md b/doc/api/util.md index 8afe7c735e6d0a..85a4a5782e1952 100644 --- a/doc/api/util.md +++ b/doc/api/util.md @@ -1262,7 +1262,7 @@ added: v10.0.0 * Returns: {boolean} Returns `true` if the value is an instance of one of the [`ArrayBuffer`][] -views, such as typed array objects or [`DataView`][]. Equivalent to +views, such as typed array objects or [`DataView`][]. Equivalent to [`ArrayBuffer.isView()`][]. ```js