Bug 1383362: Use for-of loop rather than forEach() in Services.jsm. r=florian
authorKris Maglione <maglione.k@gmail.com>
Fri, 21 Jul 2017 18:40:32 -0700
changeset 420293 6469a8fbaae429b58fc07d4a447e4c2e294328f7
parent 420292 132d97901319d76dc8e56c68b954fc86542c572c
child 420294 6679237a46723432264361b5542454bb91d4831e
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)
reviewersflorian
bugs1383362
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 1383362: Use for-of loop rather than forEach() in Services.jsm. r=florian MozReview-Commit-ID: 2IaZt3cQu59
toolkit/modules/Services.jsm
--- a/toolkit/modules/Services.jsm
+++ b/toolkit/modules/Services.jsm
@@ -108,16 +108,16 @@ var initTable = [
   ["focus", "@mozilla.org/focus-manager;1", "nsIFocusManager"],
   ["uriFixup", "@mozilla.org/docshell/urifixup;1", "nsIURIFixup"],
   ["blocklist", "@mozilla.org/extensions/blocklist;1", "nsIBlocklistService"],
   ["netUtils", "@mozilla.org/network/util;1", "nsINetUtil"],
   ["loadContextInfo", "@mozilla.org/load-context-info-factory;1", "nsILoadContextInfoFactory"],
   ["qms", "@mozilla.org/dom/quota-manager-service;1", "nsIQuotaManagerService"],
 ];
 
-initTable.forEach(([name, contract, intf, enabled = true]) => {
+for (let [name, contract, intf, enabled = true] of initTable) {
   if (enabled) {
     XPCOMUtils.defineLazyServiceGetter(Services, name, contract, intf);
   }
-});
+}
 
 
 initTable = undefined;