wrap node-multiparty with promisifyAll bluebird
问题 I'm new with node.js, I'm trying to wrap node-multiparty callbacks with bluebird but the parse function signature of multiparty is function(err, fields, files) and the promise signature requires just one return value. I'm sure there is a way to do this but I haven't found anything yet. Thanks in advance! 回答1: Use spread instead of then . Taking from the example in their README: var Promise = require('bluebird'); var multiparty = Promise.promisifyAll(require('multiparty')); var http = require(