mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 19:35:51 +00:00
Bug 1242505 - Part 1 - Handle more rejections in code exercised by browser-chrome tests. r=Mossop
MozReview-Commit-ID: JTMgC2XwzX2 --HG-- extra : rebase_source : 279cabcd658b3877a8501df382804ae5fa7aa1fc extra : source : b59573695517b2a464f22e00bd3792c50dcf371a
This commit is contained in:
parent
a002e5d1d1
commit
0369d7414c
@ -108,6 +108,8 @@ class BasePopup {
|
||||
|
||||
this.destroyed = true;
|
||||
this.browserLoadedDeferred.reject(new Error("Popup destroyed"));
|
||||
// Ignore unhandled rejections if the "attach" method is not called.
|
||||
this.browserLoaded.catch(() => {});
|
||||
|
||||
BasePopup.instances.get(this.window).delete(this.extension);
|
||||
|
||||
|
@ -1310,7 +1310,7 @@ var SessionStoreInternal = {
|
||||
// Let everyone know we're done.
|
||||
this._deferredInitialized.resolve();
|
||||
}
|
||||
}, console.error);
|
||||
}).catch(console.error);
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -255,7 +255,8 @@ this.PreferenceExperiments = {
|
||||
preferenceName,
|
||||
observer(newValue) {
|
||||
if (newValue !== preferenceValue) {
|
||||
PreferenceExperiments.stop(experimentName, false);
|
||||
PreferenceExperiments.stop(experimentName, false)
|
||||
.catch(Cu.reportError);
|
||||
}
|
||||
},
|
||||
};
|
||||
|
@ -383,7 +383,7 @@ this.TabCrashHandler = {
|
||||
CrashSubmit.submit(dumpID, {
|
||||
recordSubmission: true,
|
||||
extraExtraKeyVals,
|
||||
}).then(null, Cu.reportError);
|
||||
}).catch(Cu.reportError);
|
||||
|
||||
this.prefs.setBoolPref("sendReport", true);
|
||||
this.prefs.setBoolPref("includeURL", includeURL);
|
||||
@ -881,7 +881,7 @@ this.UnsubmittedCrashHandler = {
|
||||
extraExtraKeyVals: {
|
||||
"SubmittedFromInfobar": true,
|
||||
},
|
||||
});
|
||||
}).catch(Cu.reportError);
|
||||
}
|
||||
},
|
||||
};
|
||||
@ -995,7 +995,7 @@ this.PluginCrashReporter = {
|
||||
});
|
||||
|
||||
if (browserDumpID)
|
||||
CrashSubmit.submit(browserDumpID);
|
||||
CrashSubmit.submit(browserDumpID).catch(Cu.reportError);
|
||||
|
||||
this.broadcastState(runID, "submitting");
|
||||
|
||||
|
@ -290,7 +290,7 @@ var WebExtensionInspectedWindowActor = protocol.ActorClassWithSpec(
|
||||
})
|
||||
.catch(err => {
|
||||
delete this.customizedReload;
|
||||
throw err;
|
||||
console.error(err);
|
||||
});
|
||||
} catch (err) {
|
||||
// Cancel the customized reload (if any) on exception during the
|
||||
|
Loading…
Reference in New Issue
Block a user