Skip to content

Commit

Permalink
doc: update mode type for fs open() functions
Browse files Browse the repository at this point in the history
This commit updates the documentation for fs.open(),
fs.openSync(), and fsPromises.open() to reflect the fact
that their mode option can be a string.

PR-URL: #31115
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: David Carlier <devnexen@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
  • Loading branch information
cjihrig authored and BethGriggs committed Feb 6, 2020
1 parent e104e72 commit f851d9f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions doc/api/fs.md
Expand Up @@ -2601,7 +2601,7 @@ changes:
* `path` {string|Buffer|URL}
* `flags` {string|number} See [support of file system `flags`][].
**Default:** `'r'`.
* `mode` {integer} **Default:** `0o666` (readable and writable)
* `mode` {string|integer} **Default:** `0o666` (readable and writable)
* `callback` {Function}
* `err` {Error}
* `fd` {integer}
Expand Down Expand Up @@ -2693,7 +2693,7 @@ changes:
* `path` {string|Buffer|URL}
* `flags` {string|number} **Default:** `'r'`.
See [support of file system `flags`][].
* `mode` {integer} **Default:** `0o666`
* `mode` {string|integer} **Default:** `0o666`
* Returns: {number}

Returns an integer representing the file descriptor.
Expand Down Expand Up @@ -4848,7 +4848,7 @@ changes:
* `path` {string|Buffer|URL}
* `flags` {string|number} See [support of file system `flags`][].
**Default:** `'r'`.
* `mode` {integer} **Default:** `0o666` (readable and writable)
* `mode` {string|integer} **Default:** `0o666` (readable and writable)
* Returns: {Promise}

Asynchronous file open that returns a `Promise` that, when resolved, yields a
Expand Down

0 comments on commit f851d9f

Please sign in to comment.