Array of filenames to file node

Hi everyone, i'm running NR in v0.19.2 (this happen to me also with newer versions) when i run this code:

https://pastebin.com/qXgxMHcD

it only brings the last file, why is this? the first debug node shows all the data, but the second one, after de first file manager, only shows the last one

What "file manager" ?

Sorry, the file node.

Which file node, file node of file-in node ?

You need to give us something to work with. We don't have your files thus cannot reproduce.

Sorry, kinda shocked here jaja. The entire flow is in the pastebin that i've posted, the node that i referring is the file in, i think that the files has nothing to do with the problem, but they are all 39kb images. if you want i can upload a couple to mega.

So you have an array of images.

What do you do with the array ? Hint: not much.

Function node will return 1 message only.

Do you want to send them all to the file node ?
If yes, you will have to loop through the array of images and use node.send

eg in the bottom of your function node, replace return msg with this:

for(x=0;x<lista.length;x++){
    filename = "C:\\RecopilacionDatos\\prueba" + lista[x].nombre + ".jpg";
    node.send({payload:filename})
    
}

i want to copy, paste and rename al the image files, the "imagen" property is the current name and the "nombre" property is the final name, the first function retrieves the location of each of the files and the index, so when the second function receives it can rename it. Since there are at least 2500 images i cant just send all the messages with out limit the rate, so far so good. When the "file in" returns the file in the msg.payload it only retrieves the last index of the array and the last file (and repeat this message lista.length times, so i have 2500 equal mesagges with the data of the last index), even when the rate limit node didn't send the last one.