From 1e1bdfef8e2f0b6ae055b2e3948ca63367df461c Mon Sep 17 00:00:00 2001 From: Tim Ruffles Date: Wed, 11 Jul 2018 10:10:42 +0100 Subject: [PATCH 1/2] fs: fix readdirSync docs, doesn't accept a callback --- doc/api/fs.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index 3f19ccc3cd526b..b02830e45e6083 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -2336,7 +2336,7 @@ Synchronous readdir(3). The optional `options` argument can be a string specifying an encoding, or an object with an `encoding` property specifying the character encoding to use for -the filenames passed to the callback. If the `encoding` is set to `'buffer'`, +the filenames returned. If the `encoding` is set to `'buffer'`, the filenames returned will be passed as `Buffer` objects. ## fs.readFile(path[, options], callback) From 4241f492e04dfe0a69730cb6e4e0e6291d9937d8 Mon Sep 17 00:00:00 2001 From: Vse Mozhet Byt Date: Wed, 18 Jul 2018 22:23:21 +0300 Subject: [PATCH 2/2] fixup: fix some descriptions of sync methods --- doc/api/fs.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/api/fs.md b/doc/api/fs.md index b02830e45e6083..6db65285b3e306 100644 --- a/doc/api/fs.md +++ b/doc/api/fs.md @@ -2508,7 +2508,7 @@ Synchronous readlink(2). Returns the symbolic link's string value. The optional `options` argument can be a string specifying an encoding, or an object with an `encoding` property specifying the character encoding to use for -the link path passed to the callback. If the `encoding` is set to `'buffer'`, +the link path returned. If the `encoding` is set to `'buffer'`, the link path returned will be passed as a `Buffer` object. ## fs.readSync(fd, buffer, offset, length, position) @@ -2666,7 +2666,7 @@ Only paths that can be converted to UTF8 strings are supported. The optional `options` argument can be a string specifying an encoding, or an object with an `encoding` property specifying the character encoding to use for -the path passed to the callback. If the `encoding` is set to `'buffer'`, +the path returned. If the `encoding` is set to `'buffer'`, the path returned will be passed as a `Buffer` object. On Linux, when Node.js is linked against musl libc, the procfs file system must