Loading browser/components/newidentity/content/newidentity.js +10 −0 Original line number Diff line number Diff line Loading @@ -144,6 +144,7 @@ XPCOMUtils.defineLazyGetter(this, "NewIdentityButton", () => { this.clearStorage(); this.clearPreferencesAndPermissions(); await this.clearData(); await this.reloadAddons(); this.clearConnections(); this.clearPrivateSession(); } Loading Loading @@ -414,6 +415,15 @@ XPCOMUtils.defineLazyGetter(this, "NewIdentityButton", () => { Services.obs.notifyObservers(null, "last-pb-context-exited"); } async reloadAddons() { logger.info("Reloading add-ons to clear their temporary state."); // Reload all active extensions except search engines, which would throw. const addons = ( await AddonManager.getAddonsByTypes(["extension"]) ).filter(a => a.isActive && !a.id.endsWith("@search.mozilla.org")); await Promise.all(addons.map(a => a.reload())); } // Broadcast as a hook to clear other data broadcast() { Loading Loading
browser/components/newidentity/content/newidentity.js +10 −0 Original line number Diff line number Diff line Loading @@ -144,6 +144,7 @@ XPCOMUtils.defineLazyGetter(this, "NewIdentityButton", () => { this.clearStorage(); this.clearPreferencesAndPermissions(); await this.clearData(); await this.reloadAddons(); this.clearConnections(); this.clearPrivateSession(); } Loading Loading @@ -414,6 +415,15 @@ XPCOMUtils.defineLazyGetter(this, "NewIdentityButton", () => { Services.obs.notifyObservers(null, "last-pb-context-exited"); } async reloadAddons() { logger.info("Reloading add-ons to clear their temporary state."); // Reload all active extensions except search engines, which would throw. const addons = ( await AddonManager.getAddonsByTypes(["extension"]) ).filter(a => a.isActive && !a.id.endsWith("@search.mozilla.org")); await Promise.all(addons.map(a => a.reload())); } // Broadcast as a hook to clear other data broadcast() { Loading