Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Commit 35ec9e0

Browse files
toddpressbenhalverson
authored andcommitted
clarify file creation in flags section
I think "The file is created if it does not exist" may read more clearly to international users. Thanks!
1 parent 055e15b commit 35ec9e0

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

  • src/documentation/0044-node-writing-files

src/documentation/0044-node-writing-files/index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,9 +49,9 @@ fs.writeFile('/Users/joe/test.txt', content, { flag: 'a+' }, err => {})
4949
The flags you'll likely use are
5050

5151
* `r+` open the file for reading and writing
52-
* `w+` open the file for reading and writing, positioning the stream at the beginning of the file. The file is created if not existing
53-
* `a` open the file for writing, positioning the stream at the end of the file. The file is created if not existing
54-
* `a+` open the file for reading and writing, positioning the stream at the end of the file. The file is created if not existing
52+
* `w+` open the file for reading and writing, positioning the stream at the beginning of the file. The file is created if it does not exist
53+
* `a` open the file for writing, positioning the stream at the end of the file. The file is created if it does not exist
54+
* `a+` open the file for reading and writing, positioning the stream at the end of the file. The file is created if it does not exist
5555

5656
(you can find more flags at <https://nodejs.org/api/fs.html#fs_file_system_flags>)
5757

0 commit comments

Comments
 (0)