My code receives write a file, however, it needs to check if the file already exists and, if it exists, rename it. Is it possible to do this without using fs.existsSync ?
My current code:
fs.readFile(file.path, function (err, data) {...
asked by
09.01.2018 / 02:45