}, this.answers)
)
.toPromise(Promise)
- .then(this.onCompletion.bind(this));
+ .then(this.onCompletion.bind(this), this.onError.bind(this));
}
/**
return this.answers;
}
+ onError(error) {
+ this.close();
+ return Promise.reject(error);
+ }
+
processQuestion(question) {
question = _.clone(question);
return defer(() => {