mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-11-09 21:49:43 -05:00
Fixed unlink() required callback in NodeJS v10.
This commit is contained in:
@@ -580,12 +580,6 @@ function CreateMeshCentralServer(config, args) {
|
||||
if (restoreFile) {
|
||||
obj.debug(1, 'Server stopped, updating settings: ' + restoreFile);
|
||||
console.log('Updating settings folder...');
|
||||
/*
|
||||
var unzip = require('unzip');
|
||||
var rs = obj.fs.createReadStream(restoreFile);
|
||||
rs.on('end', () => { setTimeout(function () { fs.unlinkSync(restoreFile); process.exit(123); }, 500); });
|
||||
rs.pipe(unzip.Extract({ path: obj.datapath }));
|
||||
*/
|
||||
|
||||
var yauzl = require("yauzl");
|
||||
yauzl.open(restoreFile, { lazyEntries: true }, function (err, zipfile) {
|
||||
|
||||
Reference in New Issue
Block a user