Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

112
Views
NodeJS Dynamic Files downloads

im new to programming and i have this app that takes input from the user in a form and generates a pdf to download.

However the issue im experimenting is if 2 or more users do the process at the same time the download file for all users becomes the last file generated.

Thank you very much in advanced for helping.

var zip = new AdmZip();
        var fs=require('fs-extra');
        let arr = ['./Facturas/' + pdfFileName + '/'  + pdfFileName + '.pdf', './Facturas/' + pdfFileName + '/' + xmlFileName + '.xml']
        for(let i = 0 ;i<arr.length ;i++){
          zip.addLocalFile(`./${arr[i]}`); //local path
        }
        zip.writeZip('./Facturas/' + pdfFileName + '.zip');


        var file = '../Facturas/' + putopdf + '.zip';
        res.sendFile(file); // Set disposition and send
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!