MCPcopy Index your code
hub / github.com/nodejs/node / vfsResult

Function vfsResult

lib/fs.js:208–212  ·  view source on GitHub ↗

* Route VFS async result (Promise) to error-first callback. * @param {Promise|undefined} promise The VFS handler result * @param {Function} callback The error-first callback * @returns {boolean} true if VFS handled, false otherwise

(promise, callback)

Source from the content-addressed store, hash-verified

206 * @returns {boolean} true if VFS handled, false otherwise
207 */
208function vfsResult(promise, callback) {
209 if (promise === undefined) return false;
210 PromisePrototypeThen(promise, (result) => callback(null, result), callback);
211 return true;
212}
213
214/**
215 * Route VFS async void result to error-first callback.

Callers 10

readFileFunction · 0.85
openFunction · 0.85
readdirFunction · 0.85
fstatFunction · 0.85
lstatFunction · 0.85
statFunction · 0.85
readlinkFunction · 0.85
realpathFunction · 0.85
fs.jsFile · 0.85
mkdtempFunction · 0.85

Calls 1

callbackFunction · 0.50

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…