Bug 1478650 - Use destructuring assignment for optional removeTab parameters. r=Gijs

MozReview-Commit-ID: HVxGD44yiSy

--HG--
extra : rebase_source : 4cccc96298e17d7c6e10469fff0f718f8dfac08e
This commit is contained in:
Dão Gottwald 2018-07-26 15:31:55 +02:00
parent 14a5c3ea7a
commit f975ec5a3f

View File

@ -2621,13 +2621,11 @@ window._gBrowser = {
this.removeTab(this.selectedTab, aParams);
},
removeTab(aTab, aParams) {
if (aParams) {
var animate = aParams.animate;
var byMouse = aParams.byMouse;
var skipPermitUnload = aParams.skipPermitUnload;
}
removeTab(aTab, {
animate,
byMouse,
skipPermitUnload,
} = {}) {
// Telemetry stopwatches may already be running if removeTab gets
// called again for an already closing tab.
if (!TelemetryStopwatch.running("FX_TAB_CLOSE_TIME_ANIM_MS", aTab) &&