handle function(err, res) automatically with Q promise return