Skip to content

Commit 4ef2b5f

Browse files
doc: Replace util.debug with console.error
PR-URL: #2214 Reviewed-By: Jeremiah Senkpiel <[email protected]> Reviewed-By: Sakthipriyan Vairamani <[email protected]>
1 parent eb35968 commit 4ef2b5f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

doc/api/fs.markdown

+3-3
Original file line numberDiff line numberDiff line change
@@ -675,7 +675,7 @@ Test whether or not the given path exists by checking with the file system.
675675
Then call the `callback` argument with either true or false. Example:
676676

677677
fs.exists('/etc/passwd', function (exists) {
678-
util.debug(exists ? "it's there" : "no passwd!");
678+
console.log(exists ? "it's there" : 'no passwd!');
679679
});
680680

681681
`fs.exists()` is an anachronism and exists only for historical reasons.
@@ -717,8 +717,8 @@ a possible error argument. If any of the accessibility checks fail, the error
717717
argument will be populated. The following example checks if the file
718718
`/etc/passwd` can be read and written by the current process.
719719

720-
fs.access('/etc/passwd', fs.R_OK | fs.W_OK, function(err) {
721-
util.debug(err ? 'no access!' : 'can read/write');
720+
fs.access('/etc/passwd', fs.R_OK | fs.W_OK, function (err) {
721+
console.log(err ? 'no access!' : 'can read/write');
722722
});
723723

724724
## fs.accessSync(path[, mode])

0 commit comments

Comments
 (0)