Bug 1403473 - Init loggingEnable for hashcompleter
MozReview-Commit-ID: 1BpErwmbgCM
--- a/toolkit/components/url-classifier/nsUrlClassifierHashCompleter.js
+++ b/toolkit/components/url-classifier/nsUrlClassifierHashCompleter.js
@@ -180,16 +180,18 @@ function HashCompleter() {
// Whether we have been informed of a shutdown by the shutdown event.
this._shuttingDown = false;
// A map of gethash URLs to next gethash time in miliseconds
this._nextGethashTimeMs = {};
Services.obs.addObserver(this, "quit-application");
Services.prefs.addObserver(PREF_DEBUG_ENABLED, this);
+
+ loggingEnabled = Services.prefs.getBoolPref(PREF_DEBUG_ENABLED);
}
HashCompleter.prototype = {
classID: Components.ID("{9111de73-9322-4bfc-8b65-2b727f3e6ec8}"),
QueryInterface: XPCOMUtils.generateQI([Ci.nsIUrlClassifierHashCompleter,
Ci.nsIRunnable,
Ci.nsIObserver,
Ci.nsISupportsWeakReference,