Skip to content

Commit 3aaa707

Browse files
committed
fix: check falsy instead of explicit check
1 parent 232e0a3 commit 3aaa707

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/internal/fs/recursive_watch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,7 @@ class FSWatcher extends EventEmitter {
229229
this.#watchFolder(filename);
230230
}
231231
} catch (error) {
232-
if (this.#options.throwIfNoEntry !== false && error.code === 'ENOENT') {
232+
if (!this.#options.throwIfNoEntry && error.code === 'ENOENT') {
233233
error.filename = filename;
234234
throw error;
235235
}

0 commit comments

Comments
 (0)