Simplified code using async.map function.