code cleaning, async.waterfall