With dpd-fileupload, you can upload many files within the same request.
With node > 4.1 it leads to the error E11000: duplicate key error
The problem is located in this function:
https://github.com/deployd/deployd/blob/master/lib/db.js#L288
The variable object on line 293 is not the right one, it's using the latest given in this function due to the different scope.
To fix it, we need to pass the right object all the way to the insert.