fixed stupid bug which transferred all the output files, even the ones that didnt finish