Skip to content

How to search multiple file in ftp? #262

Open

Description

@JeffersonJiao

I need to get a report like data to get the file that is not on the FTP server. I have the code below but i cannot get the data.

listOfFile =['1.pdf','2.pdf','3.pdf'];
lisfOfNotFound = [];
for(var i=0; i<listOFfile.length;i++){
var c = new Client();
c.on("ready", function() {
console.log(list[0].shipment_id);
for (var i = 0; i < list.length; i++) {
c .get(${list[i]}.pdf,
function(err, data) {
if (err){
lisfOfNotFound.push(list[i])
}
c.end();
}
);
}
});
c.connect(config.ftp);
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions