不要怂,就是干,撸起袖子干!

Commit ee80e9de by Rachel Higley

Changing to promise-style

1 parent 009f4dab
Showing with 2 additions and 2 deletions
...@@ -162,12 +162,12 @@ module.exports = (function() { ...@@ -162,12 +162,12 @@ module.exports = (function() {
var self = this; var self = this;
emitter emitter
.success(function(result) { .then(function(result) {
self.emitterResults[self.emitters.indexOf(emitter)] = result; self.emitterResults[self.emitters.indexOf(emitter)] = result;
self.finishedEmits++; self.finishedEmits++;
finish.call(self, 'emitterResults'); finish.call(self, 'emitterResults');
}) })
.error(function(err) { .catch(function(err) {
self.finishedEmits++; self.finishedEmits++;
self.fails.push(err); self.fails.push(err);
finish.call(self, 'emitterResults'); finish.call(self, 'emitterResults');
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!