Wrapping imported construtor in a promise
问题 I have the same problem as Promisify imported class (constructor) with bluebird in ES6 + babel. The accepted answer seems to have a bug but I couldnt comment on that thread (not enough reputation points), so am creating a new question. The bug seems to be in: var o = new lib.C(); // get object o.then(function(data){ // access data }); I get a run-time error: ~/node_modules/bluebird/js/main/promise.js:114 return this._then(didFulfill, didReject, didProgress, ^ TypeError: undefined is not a