const Client = require('ftp');
let c = new Client();
c.on('ready', function () {
c.list(function (err, list) {
if (err) throw err;
console.log(list);
});
});
c.connect({
host: 'test.com',
user: 'user',
password: 'password',
secure: true
});
It works well independently,but an error occurred when running in Electron after using LIST command: "SSL connection failed: session reuse required".