Fixing the race condition where the failed job would be deleted form the input folder before it could be saved
Moving forking into a separate method