Bug 1383909 - Add observer notification when UserAgentOverrides.jsm finishes initializing. r=mcmanus
authorDennis Schubert <dschubert@mozilla.com>
Mon, 24 Jul 2017 23:25:51 +0200
changeset 420181 b8c498fb8223517460c4124cb3d822718cc6e38a
parent 420180 ef7dac1fb60080478040a1f33510c3da65784ae5
child 420182 7f9034bfd0c60fc5ec4097640f1197833e060f4a
push id7566
push usermtabara@mozilla.com
push dateWed, 02 Aug 2017 08:25:16 +0000
treeherdermozilla-beta@86913f512c3c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmcmanus
bugs1383909
milestone56.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1383909 - Add observer notification when UserAgentOverrides.jsm finishes initializing. r=mcmanus MozReview-Commit-ID: BPMzszXmhbC
netwerk/protocol/http/UserAgentOverrides.jsm
--- a/netwerk/protocol/http/UserAgentOverrides.jsm
+++ b/netwerk/protocol/http/UserAgentOverrides.jsm
@@ -62,16 +62,17 @@ this.UserAgentOverrides = {
       });
 
       buildOverrides();
     } catch (e) {
       // UserAgentOverrides is initialized before profile is ready.
       // UA override might not work correctly.
     }
 
+    Services.obs.notifyObservers(null, "useragentoverrides-initialized");
     gInitialized = true;
   },
 
   addComplexOverride: function uao_addComplexOverride(callback) {
     // Add to front of array so complex overrides have precedence
     gOverrideFunctions.unshift(callback);
   },