MCPcopy Index your code
hub / github.com/nodejs/node / #unwatchFiles

Method #unwatchFiles

lib/internal/fs/recursive_watch.js:107–119  ·  view source on GitHub ↗
(file)

Source from the content-addressed store, hash-verified

105 }
106
107 #unwatchFiles(file) {
108 this.#symbolicFiles.delete(file);
109
110 const childPrefix = file + pathSep;
111 for (const filename of this.#files.keys()) {
112 if (filename === file ||
113 StringPrototypeStartsWith(filename, childPrefix)) {
114 this.#files.delete(filename);
115 this.#watchers.get(filename)?.close();
116 this.#watchers.delete(filename);
117 }
118 }
119 }
120
121 #watchFolder(folder) {
122 const { readdirSync } = lazyLoadFsSync();

Callers 1

#watchFileMethod · 0.95

Calls 4

deleteMethod · 0.65
keysMethod · 0.65
closeMethod · 0.65
getMethod · 0.65

Tested by

no test coverage detected