Bug 1037170 - Fire oncancel() when user cancels Sign Up/Sign In. r=jedp

This commit is contained in:
Sam Penrose 2014-07-10 18:24:46 -07:00
parent b82961efc1
commit ad61403660

View File

@ -185,9 +185,10 @@ FxAccountsService.prototype = {
this.doLogin(aRPId, data); this.doLogin(aRPId, data);
}, },
error => { error => {
log.error("get assertion failed: " + JSON.stringify(error)); log.debug("get assertion failed: " + JSON.stringify(error));
// Cancellation is passed through an error channel; here we reroute. // Cancellation is passed through an error channel; here we reroute.
if (error.error && (error.error.details == "DIALOG_CLOSED_BY_USER")) { if ((error.error && (error.error.details == "DIALOG_CLOSED_BY_USER")) ||
(error.details == "DIALOG_CLOSED_BY_USER")) {
return this.doCancel(aRPId); return this.doCancel(aRPId);
} }
this.doError(aRPId, error); this.doError(aRPId, error);