jsftp
jsftp copied to clipboard
Question: Do I need to explicitly close the connection?
Do I have to call the ftp.raw.quit function at some point in the code, or will the connection be closed properly automatically?
I have ftp.on('error', err => {...});
should I be closing something or doing something in the ftp.on('error') call?
what about the fileStream that is returned from ftp.get(file, (err, fileStream) => {...})? Do I need to close/quit that fileStream explicitly?
Thanks for the help.
ftp.raw("QUIT"); ftp.destroy();