# HG changeset patch # User Magnus Melin # Date 1757493192 0 # Node ID 1cc168c9d0a5c55744d2886aa380f5a7bf712ef4 # Parent 20980bc07105ebb761347e9c99937e572eedf03a Bug 1987834 - Don't remove not added observer of AUTO_UPDATE_CHANGED_TOPIC when MOZ_UPDATER is off. r=john.bieling Differential Revision: https://phabricator.services.mozilla.com/D264376 diff --git a/mail/components/preferences/general.js b/mail/components/preferences/general.js --- a/mail/components/preferences/general.js +++ b/mail/components/preferences/general.js @@ -2175,17 +2175,19 @@ var gGeneralPane = { } return /^https?/.test(uri.scheme) ? uri.resolve("/favicon.ico") : ""; }, destroy() { window.removeEventListener("unload", this); - Services.obs.removeObserver(this, AUTO_UPDATE_CHANGED_TOPIC); + if (AppConstants.MOZ_UPDATER) { + Services.obs.removeObserver(this, AUTO_UPDATE_CHANGED_TOPIC); + } Services.prefs.removeObserver("mailnews.tags.", this); }, // nsISupports QueryInterface: ChromeUtils.generateQI(["nsIObserver"]), // nsIObserver