If we call fs.copyFile with flags, the parameter callback misses:
const fs = require('fs-extra'); // `fs.copyFile` called grancful-fs.copyFile
async function copy(src, dest) {
console.log('start');
await fs.copyFile(src, dest, fs.constants.COPYFILE_FICLONE);
console.log('end'); // never get this line
}
copy(__filename, './another-file.js');
If we call
fs.copyFile
with flags, the parametercallback
misses: