Bug 1316882: Turn on space-before-function-paren eslint rule (toolkit). r=jaws
authorDave Townsend <dtownsend@oxymoronical.com>
Fri, 11 Nov 2016 15:22:34 -0800
changeset 367766 4873321befff7cc0c251b34b29192140070f1702
parent 367765 dfa1b55da2b1a0d1ab60f20f0540d1ede684ea0b
child 367767 fa4c2f76351daff538a681fde73797395fac5514
push id6996
push userjlorenzo@mozilla.com
push dateMon, 06 Mar 2017 20:48:21 +0000
treeherdermozilla-beta@d89512dab048 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjaws
bugs1316882
milestone53.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 1316882: Turn on space-before-function-paren eslint rule (toolkit). r=jaws MozReview-Commit-ID: FGFwg6TYkvm
toolkit/.eslintrc.js
toolkit/components/addoncompat/RemoteAddonsParent.jsm
toolkit/components/alerts/test/test_alerts.html
toolkit/components/autocomplete/tests/unit/head_autocomplete.js
toolkit/components/autocomplete/tests/unit/test_378079.js
toolkit/components/autocomplete/tests/unit/test_393191.js
toolkit/components/autocomplete/tests/unit/test_440866.js
toolkit/components/autocomplete/tests/unit/test_autocomplete_multiple.js
toolkit/components/autocomplete/tests/unit/test_autocomplete_userContextId.js
toolkit/components/autocomplete/tests/unit/test_badDefaultIndex.js
toolkit/components/autocomplete/tests/unit/test_previousResult.js
toolkit/components/autocomplete/tests/unit/test_stopSearch.js
toolkit/components/captivedetect/captivedetect.js
toolkit/components/captivedetect/test/unit/test_captive_portal_found_303.js
toolkit/components/contentprefs/ContentPrefService2.jsm
toolkit/components/contentprefs/tests/unit/test_bug503971.js
toolkit/components/contentprefs/tests/unit/test_contentPrefsCache.js
toolkit/components/contentprefs/tests/unit/test_stringGroups.js
toolkit/components/contentprefs/tests/unit_cps2/head.js
toolkit/components/contentprefs/tests/unit_cps2/test_setGet.js
toolkit/components/contextualidentity/ContextualIdentityService.jsm
toolkit/components/crashes/CrashManager.jsm
toolkit/components/crashes/CrashManagerTest.jsm
toolkit/components/crashes/CrashService.js
toolkit/components/crashmonitor/CrashMonitor.jsm
toolkit/components/crashmonitor/nsCrashMonitor.js
toolkit/components/ctypes/tests/unit/test_jsctypes.js
toolkit/components/downloads/test/unit/test_app_rep_windows.js
toolkit/components/exthelper/extApplication.js
toolkit/components/filepicker/nsFilePicker.js
toolkit/components/formautofill/FormAutofillContentService.js
toolkit/components/formautofill/FormAutofillStartup.js
toolkit/components/formautofill/content/RequestAutocompleteUI.jsm
toolkit/components/formautofill/content/requestAutocomplete.js
toolkit/components/formautofill/test/browser/loader.js
toolkit/components/formautofill/test/chrome/loader.js
toolkit/components/formautofill/test/chrome/loader_parent.js
toolkit/components/formautofill/test/head_common.js
toolkit/components/formautofill/test/loader_common.js
toolkit/components/formautofill/test/xpcshell/loader.js
toolkit/components/gfx/content/gfxFrameScript.js
toolkit/components/jsdownloads/src/DownloadCore.jsm
toolkit/components/jsdownloads/src/DownloadImport.jsm
toolkit/components/jsdownloads/src/DownloadLegacy.js
toolkit/components/jsdownloads/src/DownloadList.jsm
toolkit/components/jsdownloads/src/DownloadStore.jsm
toolkit/components/jsdownloads/src/DownloadUIHelper.jsm
toolkit/components/jsdownloads/src/Downloads.jsm
toolkit/components/jsdownloads/test/browser/head.js
toolkit/components/jsdownloads/test/unit/common_test_Download.js
toolkit/components/jsdownloads/test/unit/head.js
toolkit/components/jsdownloads/test/unit/test_DownloadImport.js
toolkit/components/jsdownloads/test/unit/test_DownloadIntegration.js
toolkit/components/jsdownloads/test/unit/test_DownloadList.js
toolkit/components/jsdownloads/test/unit/test_DownloadStore.js
toolkit/components/microformats/microformat-shiv.js
toolkit/components/microformats/update/update.js
toolkit/components/passwordmgr/LoginImport.jsm
toolkit/components/passwordmgr/LoginManagerContent.jsm
toolkit/components/passwordmgr/LoginManagerParent.jsm
toolkit/components/passwordmgr/LoginRecipes.jsm
toolkit/components/passwordmgr/LoginStore.jsm
toolkit/components/passwordmgr/crypto-SDR.js
toolkit/components/passwordmgr/nsLoginInfo.js
toolkit/components/passwordmgr/nsLoginManagerPrompter.js
toolkit/components/passwordmgr/storage-json.js
toolkit/components/passwordmgr/storage-mozStorage.js
toolkit/components/passwordmgr/test/browser/browser_hasInsecureLoginForms_streamConverter.js
toolkit/components/passwordmgr/test/browser/browser_insecurePasswordWarning.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgr_contextmenu.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgr_editing.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgr_fields.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgr_observers.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgr_sort.js
toolkit/components/passwordmgr/test/browser/browser_passwordmgrdlg.js
toolkit/components/passwordmgr/test/browser/formless_basic.html
toolkit/components/passwordmgr/test/mochitest/test_prompt_promptAuth_proxy.html
toolkit/components/passwordmgr/test/prompt_common.js
toolkit/components/passwordmgr/test/test_prompt_async.html
toolkit/components/passwordmgr/test/test_xhr.html
toolkit/components/passwordmgr/test/unit/head.js
toolkit/components/passwordmgr/test/unit/test_module_LoginImport.js
toolkit/components/passwordmgr/test/unit/test_notifications.js
toolkit/components/passwordmgr/test/unit/test_telemetry.js
toolkit/components/perfmonitoring/tests/browser/browser_AddonWatcher.js
toolkit/components/places/BookmarkHTMLUtils.jsm
toolkit/components/places/History.jsm
toolkit/components/places/PlacesDBUtils.jsm
toolkit/components/places/PlacesSearchAutocompleteProvider.jsm
toolkit/components/places/PlacesSyncUtils.jsm
toolkit/components/places/PlacesTransactions.jsm
toolkit/components/places/PlacesUtils.jsm
toolkit/components/places/UnifiedComplete.js
toolkit/components/places/nsLivemarkService.js
toolkit/components/places/nsPlacesExpiration.js
toolkit/components/places/nsTaggingService.js
toolkit/components/places/tests/bookmarks/test_393498.js
toolkit/components/places/tests/bookmarks/test_405938_restore_queries.js
toolkit/components/places/tests/bookmarks/test_424958-json-quoted-folders.js
toolkit/components/places/tests/bookmarks/test_448584.js
toolkit/components/places/tests/bookmarks/test_458683.js
toolkit/components/places/tests/bookmarks/test_711914.js
toolkit/components/places/tests/bookmarks/test_async_observers.js
toolkit/components/places/tests/bookmarks/test_nsINavBookmarkObserver.js
toolkit/components/places/tests/browser/browser_bug399606.js
toolkit/components/places/tests/browser/browser_double_redirect.js
toolkit/components/places/tests/browser/browser_favicon_setAndFetchFaviconForPage.js
toolkit/components/places/tests/browser/browser_favicon_setAndFetchFaviconForPage_failures.js
toolkit/components/places/tests/browser/browser_notfound.js
toolkit/components/places/tests/browser/browser_redirect.js
toolkit/components/places/tests/browser/browser_visited_notfound.js
toolkit/components/places/tests/browser/browser_visituri_privatebrowsing_perwindowpb.js
toolkit/components/places/tests/browser/head.js
toolkit/components/places/tests/favicons/head_favicons.js
toolkit/components/places/tests/favicons/test_favicons_conversions.js
toolkit/components/places/tests/favicons/test_getFaviconDataForPage.js
toolkit/components/places/tests/favicons/test_getFaviconURLForPage.js
toolkit/components/places/tests/head_common.js
toolkit/components/places/tests/queries/test_async.js
toolkit/components/places/tests/queries/test_containersQueries_sorting.js
toolkit/components/places/tests/queries/test_history_queries_tags_liveUpdate.js
toolkit/components/places/tests/queries/test_querySerialization.js
toolkit/components/places/tests/queries/test_redirects.js
toolkit/components/places/tests/queries/test_tags.js
toolkit/components/places/tests/queries/test_transitions.js
toolkit/components/places/tests/unifiedcomplete/head_autocomplete.js
toolkit/components/places/tests/unit/nsDummyObserver.js
toolkit/components/places/tests/unit/test_454977.js
toolkit/components/places/tests/unit/test_PlacesUtils_lazyobservers.js
toolkit/components/places/tests/unit/test_adaptive.js
toolkit/components/places/tests/unit/test_asyncExecuteLegacyQueries.js
toolkit/components/places/tests/unit/test_async_transactions.js
toolkit/components/places/tests/unit/test_bookmarks_html.js
toolkit/components/places/tests/unit/test_bookmarks_json.js
toolkit/components/places/tests/unit/test_bookmarks_restore_notification.js
toolkit/components/places/tests/unit/test_childlessTags.js
toolkit/components/places/tests/unit/test_download_history.js
toolkit/components/places/tests/unit/test_history_observer.js
toolkit/components/places/tests/unit/test_isURIVisited.js
toolkit/components/places/tests/unit/test_markpageas.js
toolkit/components/places/tests/unit/test_nsINavHistoryViewer.js
toolkit/components/places/tests/unit/test_onItemChanged_tags.js
toolkit/components/places/tests/unit/test_placesTxn.js
toolkit/components/places/tests/unit/test_preventive_maintenance.js
toolkit/components/places/tests/unit/test_preventive_maintenance_checkAndFixDatabase.js
toolkit/components/places/tests/unit/test_preventive_maintenance_runTasks.js
toolkit/components/places/tests/unit/test_resolveNullBookmarkTitles.js
toolkit/components/printing/content/printPreviewProgress.js
toolkit/components/printing/content/printProgress.js
toolkit/components/printing/content/printUtils.js
toolkit/components/printing/content/printdialog.js
toolkit/components/printing/content/printjoboptions.js
toolkit/components/privatebrowsing/PrivateBrowsingTrackingProtectionWhitelist.js
toolkit/components/processsingleton/ContentProcessSingleton.js
toolkit/components/prompts/src/CommonDialog.jsm
toolkit/components/prompts/src/SharedPromptUtils.jsm
toolkit/components/prompts/src/nsPrompter.js
toolkit/components/prompts/test/test_bug619644.html
toolkit/components/reader/AboutReader.jsm
toolkit/components/reader/ReaderMode.jsm
toolkit/components/reader/ReaderWorker.js
toolkit/components/reader/content/aboutReader.js
toolkit/components/reader/test/browser_readerMode.js
toolkit/components/satchel/FormHistory.jsm
toolkit/components/satchel/formSubmitListener.js
toolkit/components/satchel/nsFormAutoComplete.js
toolkit/components/satchel/nsFormAutoCompleteResult.jsm
toolkit/components/satchel/nsFormHistory.js
toolkit/components/satchel/nsInputListAutoComplete.js
toolkit/components/satchel/test/parent_utils.js
toolkit/components/satchel/test/test_form_autocomplete.html
toolkit/components/satchel/test/test_form_autocomplete_with_list.html
toolkit/components/satchel/test/test_form_submission.html
toolkit/components/satchel/test/test_form_submission_cap.html
toolkit/components/satchel/test/test_form_submission_cap2.html
toolkit/components/satchel/test/unit/head_satchel.js
toolkit/components/satchel/test/unit/test_async_expire.js
toolkit/components/satchel/test/unit/test_autocomplete.js
toolkit/components/satchel/test/unit/test_db_corrupt.js
toolkit/components/satchel/test/unit/test_db_update_v4.js
toolkit/components/satchel/test/unit/test_db_update_v4b.js
toolkit/components/satchel/test/unit/test_history_api.js
toolkit/components/satchel/test/unit/test_notify.js
toolkit/components/search/SearchStaticData.jsm
toolkit/components/search/SearchSuggestionController.jsm
toolkit/components/search/nsSearchService.js
toolkit/components/search/tests/xpcshell/head_search.js
toolkit/components/search/tests/xpcshell/test_addEngine_callback.js
toolkit/components/search/tests/xpcshell/test_location_malformed_json.js
toolkit/components/search/tests/xpcshell/test_location_sync.js
toolkit/components/search/tests/xpcshell/test_notifications.js
toolkit/components/search/tests/xpcshell/test_searchSuggest.js
toolkit/components/securityreporter/SecurityReporter.js
toolkit/components/startup/tests/browser/browser_bug511456.js
toolkit/components/startup/tests/browser/browser_bug537449.js
toolkit/components/startup/tests/unit/head_startup.js
toolkit/components/telemetry/TelemetryController.jsm
toolkit/components/telemetry/TelemetryEnvironment.jsm
toolkit/components/telemetry/TelemetryReportingPolicy.jsm
toolkit/components/telemetry/TelemetrySend.jsm
toolkit/components/telemetry/TelemetrySession.jsm
toolkit/components/telemetry/TelemetryStopwatch.jsm
toolkit/components/telemetry/TelemetryStorage.jsm
toolkit/components/telemetry/tests/unit/test_TelemetryEnvironment.js
toolkit/components/telemetry/tests/unit/test_TelemetryLateWrites.js
toolkit/components/telemetry/tests/unit/test_TelemetrySession.js
toolkit/components/thumbnails/BackgroundPageThumbs.jsm
toolkit/components/thumbnails/PageThumbUtils.jsm
toolkit/components/thumbnails/PageThumbs.jsm
toolkit/components/thumbnails/PageThumbsProtocol.js
toolkit/components/thumbnails/content/backgroundPageThumbsContent.js
toolkit/components/thumbnails/test/browser_thumbnails_bg_no_cookies_sent.js
toolkit/components/thumbnails/test/browser_thumbnails_bug727765.js
toolkit/components/thumbnails/test/browser_thumbnails_bug818225.js
toolkit/components/thumbnails/test/browser_thumbnails_privacy.js
toolkit/components/thumbnails/test/browser_thumbnails_redirect.js
toolkit/components/thumbnails/test/browser_thumbnails_storage.js
toolkit/components/thumbnails/test/browser_thumbnails_storage_migrate3.js
toolkit/components/thumbnails/test/browser_thumbnails_update.js
toolkit/components/thumbnails/test/head.js
toolkit/components/timermanager/nsUpdateTimerManager.js
toolkit/components/timermanager/tests/unit/consumerNotifications.js
toolkit/components/tooltiptext/TooltipTextProvider.js
toolkit/components/viewsource/content/viewSource.js
toolkit/components/xulstore/XULStore.js
toolkit/content/aboutAbout.js
toolkit/content/aboutNetworking.js
toolkit/content/aboutSupport.js
toolkit/content/aboutTelemetry.js
toolkit/content/aboutwebrtc/aboutWebrtc.js
toolkit/content/browser-child.js
toolkit/content/browser-content.js
toolkit/content/contentAreaUtils.js
toolkit/content/customizeToolbar.js
toolkit/content/tests/browser/browser_audioCompeting.js
toolkit/content/tests/browser/browser_default_image_filename.js
toolkit/content/tests/browser/browser_mediaPlayback_suspended_multipleAudio.js
toolkit/content/tests/browser/browser_save_resend_postdata.js
toolkit/content/tests/browser/common/mockTransfer.js
toolkit/content/tests/chrome/file_autocomplete_with_composition.js
toolkit/content/tests/chrome/popup_trigger.js
toolkit/content/tests/chrome/test_autocomplete_with_composition_on_input.html
toolkit/content/tests/fennec-tile-testapp/chrome/content/WidgetStack.js
toolkit/content/tests/mochitest/test_mousecapture.xhtml
toolkit/content/tests/widgets/test_videocontrols_standalone.html
toolkit/content/treeUtils.js
toolkit/content/widgets/general.xml
toolkit/content/widgets/popup.xml
toolkit/content/widgets/preferences.xml
toolkit/content/widgets/tabbox.xml
toolkit/content/widgets/toolbar.xml
toolkit/content/widgets/tree.xml
toolkit/content/widgets/videocontrols.xml
toolkit/crashreporter/test/browser/browser_aboutCrashes.js
toolkit/crashreporter/test/browser/browser_bug471404.js
toolkit/crashreporter/test/browser/browser_clearReports.js
toolkit/identity/tests/unit/head_identity.js
toolkit/identity/tests/unit/test_authentication.js
toolkit/identity/tests/unit/test_crypto_service.js
toolkit/identity/tests/unit/test_identity.js
toolkit/identity/tests/unit/test_minimalidentity.js
toolkit/identity/tests/unit/test_observer_topics.js
toolkit/identity/tests/unit/test_relying_party.js
toolkit/modules/Battery.jsm
toolkit/modules/BinarySearch.jsm
toolkit/modules/BrowserUtils.jsm
toolkit/modules/ClientID.jsm
toolkit/modules/DeferredTask.jsm
toolkit/modules/Deprecated.jsm
toolkit/modules/Finder.jsm
toolkit/modules/Integration.jsm
toolkit/modules/JSONFile.jsm
toolkit/modules/LightweightThemeConsumer.jsm
toolkit/modules/Log.jsm
toolkit/modules/NewTabUtils.jsm
toolkit/modules/PopupNotifications.jsm
toolkit/modules/ProfileAge.jsm
toolkit/modules/Promise-backend.js
toolkit/modules/PropertyListUtils.jsm
toolkit/modules/RemoteController.jsm
toolkit/modules/RemoteFinder.jsm
toolkit/modules/RemoteSecurityUI.jsm
toolkit/modules/RemoteWebProgress.jsm
toolkit/modules/SelectContentHelper.jsm
toolkit/modules/Services.jsm
toolkit/modules/SessionRecorder.jsm
toolkit/modules/Sntp.jsm
toolkit/modules/SpatialNavigation.jsm
toolkit/modules/Sqlite.jsm
toolkit/modules/Task.jsm
toolkit/modules/Troubleshoot.jsm
toolkit/modules/UpdateUtils.jsm
toolkit/modules/WebChannel.jsm
toolkit/modules/secondscreen/SimpleServiceDiscovery.jsm
toolkit/modules/sessionstore/FormData.jsm
toolkit/modules/sessionstore/ScrollPosition.jsm
toolkit/modules/sessionstore/Utils.jsm
toolkit/modules/tests/browser/browser_Battery.js
toolkit/modules/tests/browser/browser_Deprecated.js
toolkit/modules/tests/browser/browser_Finder.js
toolkit/modules/tests/browser/browser_Finder_hidden_textarea.js
toolkit/modules/tests/browser/browser_Troubleshoot.js
toolkit/modules/tests/xpcshell/test_DeferredTask.js
toolkit/modules/tests/xpcshell/test_FileUtils.js
toolkit/modules/tests/xpcshell/test_JSONFile.js
toolkit/modules/tests/xpcshell/test_NewTabUtils.js
toolkit/modules/tests/xpcshell/test_session_recorder.js
toolkit/modules/tests/xpcshell/test_sqlite.js
toolkit/modules/tests/xpcshell/test_sqlite_shutdown.js
toolkit/modules/tests/xpcshell/test_web_channel.js
toolkit/mozapps/downloads/DownloadLastDir.jsm
toolkit/mozapps/downloads/DownloadTaskbarProgress.jsm
toolkit/mozapps/downloads/content/downloads.js
toolkit/mozapps/extensions/AddonManager.jsm
toolkit/mozapps/extensions/LightweightThemeManager.jsm
toolkit/mozapps/extensions/content/update.js
toolkit/mozapps/extensions/nsBlocklistService.js
toolkit/mozapps/extensions/test/AddonManagerTesting.jsm
toolkit/mozapps/extensions/test/browser/addons/browser_inlinesettings1/bootstrap.js
toolkit/mozapps/extensions/test/browser/addons/browser_inlinesettings1_custom/bootstrap.js
toolkit/mozapps/extensions/test/browser/addons/browser_inlinesettings1_info/bootstrap.js
toolkit/mozapps/extensions/test/browser/browser_bug557956.js
toolkit/mozapps/extensions/test/browser/browser_bug562992.js
toolkit/mozapps/extensions/test/browser/browser_inlinesettings.js
toolkit/mozapps/extensions/test/browser/browser_inlinesettings_custom.js
toolkit/mozapps/extensions/test/browser/browser_inlinesettings_info.js
toolkit/mozapps/extensions/test/browser/browser_openDialog.js
toolkit/mozapps/extensions/test/browser/browser_tabsettings.js
toolkit/mozapps/extensions/test/browser/browser_webapi_install.js
toolkit/mozapps/extensions/test/browser/head.js
toolkit/mozapps/extensions/test/xpcshell/test_AddonRepository_cache.js
toolkit/mozapps/extensions/test/xpcshell/test_LightweightThemeManager.js
toolkit/mozapps/extensions/test/xpcshell/test_XPIcancel.js
toolkit/mozapps/extensions/test/xpcshell/test_isDebuggable.js
toolkit/mozapps/extensions/test/xpcshell/test_migrateAddonRepository.js
toolkit/mozapps/extensions/test/xpcshell/test_migrate_max_version.js
toolkit/mozapps/extensions/test/xpcshell/test_syncGUID.js
toolkit/mozapps/extensions/test/xpcshell/test_update.js
toolkit/mozapps/extensions/test/xpcshell/test_update_ignorecompat.js
toolkit/mozapps/extensions/test/xpinstall/browser_enabled.js
toolkit/mozapps/extensions/test/xpinstall/browser_enabled2.js
toolkit/mozapps/preferences/fontbuilder.js
toolkit/mozapps/preferences/removemp.js
toolkit/mozapps/update/content/updates.js
toolkit/mozapps/update/nsUpdateService.js
--- a/toolkit/.eslintrc.js
+++ b/toolkit/.eslintrc.js
@@ -171,17 +171,17 @@ module.exports = {
 
     // Always require semicolon at end of statement
     // "semi": ["error", "always"],
 
     // Require space before blocks
     "space-before-blocks": "error",
 
     // Never use spaces before function parentheses
-    // "space-before-function-paren": ["error", { "anonymous": "always", "named": "never" }],
+    "space-before-function-paren": ["error", "never"],
 
     // No space padding in parentheses
     // "space-in-parens": ["error", "never"],
 
     // Require spaces around operators
     "space-infix-ops": ["error", { "int32Hint": true }],
 
     // ++ and -- should not need spacing
--- a/toolkit/components/addoncompat/RemoteAddonsParent.jsm
+++ b/toolkit/components/addoncompat/RemoteAddonsParent.jsm
@@ -119,17 +119,17 @@ var ContentPolicyParent = {
     NotificationTracker.add(["content-policy", addon]);
   },
 
   removeContentPolicy: function(addon, name) {
     this._policies.delete(name);
     NotificationTracker.remove(["content-policy", addon]);
   },
 
-  receiveMessage: function (aMessage) {
+  receiveMessage: function(aMessage) {
     switch (aMessage.name) {
       case "Addons:ContentPolicy:Run":
         return this.shouldLoad(aMessage.data, aMessage.objects);
     }
     return undefined;
   },
 
   shouldLoad: function(aData, aObjects) {
@@ -214,17 +214,17 @@ var AboutProtocolParent = {
       if (this._protocols[i].factory == factory) {
         NotificationTracker.remove(["about-protocol", this._protocols[i].contractID, addon]);
         this._protocols.splice(i, 1);
         break;
       }
     }
   },
 
-  receiveMessage: function (msg) {
+  receiveMessage: function(msg) {
     switch (msg.name) {
       case "Addons:AboutProtocol:GetURIFlags":
         return this.getURIFlags(msg);
       case "Addons:AboutProtocol:OpenChannel":
         return this.openChannel(msg);
     }
     return undefined;
   },
--- a/toolkit/components/alerts/test/test_alerts.html
+++ b/toolkit/components/alerts/test/test_alerts.html
@@ -16,17 +16,17 @@
 <br>Did a notification appear anywhere?
 <br>If so, the test will finish once the notification disappears.
 
 <pre id="test">
 <script class="testbody" type="text/javascript">
 
 var observer = {
   alertShow: false,
-  observe: function (aSubject, aTopic, aData) {
+  observe: function(aSubject, aTopic, aData) {
     is(aData, "foobarcookie", "Checking whether the alert cookie was passed correctly");
     if (aTopic == "alertclickcallback") {
       todo(false, "Did someone click the notification while running mochitests? (Please don't.)");
     } else if (aTopic == "alertshow") {
       ok(!this.alertShow, "Alert should not be shown more than once");
       this.alertShow = true;
     } else {
       is(aTopic, "alertfinished", "Checking the topic for a finished notification");
--- a/toolkit/components/autocomplete/tests/unit/head_autocomplete.js
+++ b/toolkit/components/autocomplete/tests/unit/head_autocomplete.js
@@ -108,17 +108,17 @@ AutoCompleteResultBase.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this._finalCompleteValues[aIndex] || this._values[aIndex];
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIAutoCompleteResult])
 }
 
 /**
  * nsIAutoCompleteSearch implementation that always returns
  * the same result set.
--- a/toolkit/components/autocomplete/tests/unit/test_378079.js
+++ b/toolkit/components/autocomplete/tests/unit/test_378079.js
@@ -122,17 +122,17 @@ AutoCompleteResult.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this.getValueAt(aIndex);
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: function(iid) {
     if (iid.equals(Ci.nsISupports) ||
         iid.equals(Ci.nsIAutoCompleteResult))
       return this;
 
     throw Components.results.NS_ERROR_NO_INTERFACE;
--- a/toolkit/components/autocomplete/tests/unit/test_393191.js
+++ b/toolkit/components/autocomplete/tests/unit/test_393191.js
@@ -121,17 +121,17 @@ AutoCompleteResult.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this.getValueAt(aIndex);
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: function(iid) {
     if (iid.equals(Ci.nsISupports) ||
         iid.equals(Ci.nsIAutoCompleteResult))
       return this;
 
     throw Components.results.NS_ERROR_NO_INTERFACE;
--- a/toolkit/components/autocomplete/tests/unit/test_440866.js
+++ b/toolkit/components/autocomplete/tests/unit/test_440866.js
@@ -120,17 +120,17 @@ AutoCompleteResult.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this.getValueAt(aIndex);
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: function(iid) {
     if (iid.equals(Ci.nsISupports) ||
         iid.equals(Ci.nsIAutoCompleteResult))
       return this;
 
     throw Components.results.NS_ERROR_NO_INTERFACE;
--- a/toolkit/components/autocomplete/tests/unit/test_autocomplete_multiple.js
+++ b/toolkit/components/autocomplete/tests/unit/test_autocomplete_multiple.js
@@ -109,17 +109,17 @@ AutoCompleteResult.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this.getValueAt(aIndex);
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: function(iid) {
     if (iid.equals(Ci.nsISupports) ||
         iid.equals(Ci.nsIAutoCompleteResult))
       return this;
 
     throw Components.results.NS_ERROR_NO_INTERFACE;
--- a/toolkit/components/autocomplete/tests/unit/test_autocomplete_userContextId.js
+++ b/toolkit/components/autocomplete/tests/unit/test_autocomplete_userContextId.js
@@ -18,20 +18,20 @@ add_task(function *test_userContextId() 
   let searchParam = yield doSearch("test", 1);
   Assert.equal(searchParam, " user-context-id:1");
 });
 
 function doSearch(aString, aUserContextId) {
   let deferred = Promise.defer();
   let search = new AutoCompleteSearch("test");
 
-  search.startSearch = function (aSearchString,
-                                 aSearchParam,
-                                 aPreviousResult,
-                                 aListener) {
+  search.startSearch = function(aSearchString,
+                                aSearchParam,
+                                aPreviousResult,
+                                aListener) {
     unregisterAutoCompleteSearch(search);
     deferred.resolve(aSearchParam);
   };
 
   registerAutoCompleteSearch(search);
 
   let controller = Cc["@mozilla.org/autocomplete/controller;1"].
                    getService(Ci.nsIAutoCompleteController);
--- a/toolkit/components/autocomplete/tests/unit/test_badDefaultIndex.js
+++ b/toolkit/components/autocomplete/tests/unit/test_badDefaultIndex.js
@@ -41,17 +41,17 @@ add_test(function autocomplete_noMatch_s
   do_check_eq(input.selectionStart, strLen);
   do_check_eq(input.selectionEnd, strLen);
 
   let controller = Cc["@mozilla.org/autocomplete/controller;1"].
                    getService(Ci.nsIAutoCompleteController);
   controller.input = input;
   controller.startSearch(INPUT_STR);
 
-  input.onSearchComplete = function () {
+  input.onSearchComplete = function() {
     // Should not try to autoFill to an empty value.
     do_check_eq(input.textValue, "moz");
 
     // Clean up.
     unregisterAutoCompleteSearch(searchNoMatch);
     run_next_test();
   };
 });
@@ -76,17 +76,17 @@ add_test(function autocomplete_defaultIn
   do_check_eq(input.selectionStart, strLen);
   do_check_eq(input.selectionEnd, strLen);
 
   let controller = Cc["@mozilla.org/autocomplete/controller;1"].
                    getService(Ci.nsIAutoCompleteController);
   controller.input = input;
   controller.startSearch(INPUT_STR);
 
-  input.onSearchComplete = function () {
+  input.onSearchComplete = function() {
     // Should not try to autoFill to an empty value.
     do_check_eq(input.textValue, "moz");
 
     // Clean up.
     unregisterAutoCompleteSearch(searchBadIndex);
     run_next_test();
   };
 });
--- a/toolkit/components/autocomplete/tests/unit/test_previousResult.js
+++ b/toolkit/components/autocomplete/tests/unit/test_previousResult.js
@@ -120,17 +120,17 @@ AutoCompleteResult.prototype = {
   getImageAt: function(aIndex) {
     return "";
   },
 
   getFinalCompleteValueAt: function(aIndex) {
     return this.getValueAt(aIndex);
   },
 
-  removeValueAt: function (aRowIndex, aRemoveFromDb) {},
+  removeValueAt: function(aRowIndex, aRemoveFromDb) {},
 
   // nsISupports implementation
   QueryInterface: function(iid) {
     if (iid.equals(Ci.nsISupports) ||
         iid.equals(Ci.nsIAutoCompleteResult))
       return this;
 
     throw Components.results.NS_ERROR_NO_INTERFACE;
--- a/toolkit/components/autocomplete/tests/unit/test_stopSearch.js
+++ b/toolkit/components/autocomplete/tests/unit/test_stopSearch.js
@@ -30,18 +30,18 @@ AutoCompleteInput.prototype = {
   disableAutoComplete: false,
   completeDefaultIndex: false,
   set popupOpen(val) { return val; }, // ignore
   get popupOpen() { return false; },
   get searchCount() { return this.searches.length; },
   getSearchAt: function(aIndex) { return this.searches[aIndex]; },
   onSearchBegin: function() {},
   onSearchComplete: function() {},
-  onTextReverted: function () {},
-  onTextEntered: function () {},
+  onTextReverted: function() {},
+  onTextEntered: function() {},
   popup: {
     selectBy: function() {},
     invalidate: function() {},
     set selectedIndex(val) { return val; }, // ignore
     get selectedIndex() { return -1 },
     QueryInterface: XPCOMUtils.generateQI([Ci.nsIAutoCompletePopup])
   },
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIAutoCompleteInput])
--- a/toolkit/components/captivedetect/captivedetect.js
+++ b/toolkit/components/captivedetect/captivedetect.js
@@ -41,18 +41,18 @@ function URLFetcher(url, timeout) {
   // final destination. It does not help if a resource is already
   // cached locally.
   xhr.setRequestHeader("Cache-Control", "no-cache");
   // HTTP/1.0 servers might not implement Cache-Control and
   // might only implement Pragma: no-cache
   xhr.setRequestHeader("Pragma", "no-cache");
 
   xhr.timeout = timeout;
-  xhr.ontimeout = function () { self.ontimeout(); };
-  xhr.onerror = function () { self.onerror(); };
+  xhr.ontimeout = function() { self.ontimeout(); };
+  xhr.onerror = function() { self.onerror(); };
   xhr.onreadystatechange = function(oEvent) {
     if (xhr.readyState === 4) {
       if (self._isAborted) {
         return;
       }
       if (xhr.status === 200) {
         self.onsuccess(xhr.responseText);
       } else if (xhr.status) {
@@ -106,17 +106,17 @@ function LoginObserver(captivePortalDete
 
   let checkPageContent = function checkPageContent() {
     debug("checking if public network is available after the login procedure");
 
     urlFetcher = new URLFetcher(captivePortalDetector._canonicalSiteURL,
                                 captivePortalDetector._maxWaitingTime);
     urlFetcher.ontimeout = pageCheckingDone;
     urlFetcher.onerror = pageCheckingDone;
-    urlFetcher.onsuccess = function (content) {
+    urlFetcher.onsuccess = function(content) {
       if (captivePortalDetector.validateContent(content)) {
         urlFetcher = null;
         captivePortalDetector.executeCallback(true);
       } else {
         pageCheckingDone();
       }
     };
     urlFetcher.onredirectorerror = pageCheckingDone;
@@ -310,25 +310,25 @@ CaptivePortalDetector.prototype = {
     let self = this;
 
     let urlFetcher = new URLFetcher(this._canonicalSiteURL, this._maxWaitingTime);
 
     let mayRetry = this._mayRetry.bind(this);
 
     urlFetcher.ontimeout = mayRetry;
     urlFetcher.onerror = mayRetry;
-    urlFetcher.onsuccess = function (content) {
+    urlFetcher.onsuccess = function(content) {
       if (self.validateContent(content)) {
         self.executeCallback(true);
       } else {
         // Content of the canonical website has been overwrite
         self._startLogin();
       }
     };
-    urlFetcher.onredirectorerror = function (status) {
+    urlFetcher.onredirectorerror = function(status) {
       if (status >= 300 && status <= 399) {
         // The canonical website has been redirected to an unknown location
         self._startLogin();
       } else {
         mayRetry();
       }
     };
 
@@ -461,16 +461,16 @@ CaptivePortalDetector.prototype = {
         break;
       }
     }
   },
 };
 
 var debug;
 if (DEBUG) {
-  debug = function (s) {
+  debug = function(s) {
     dump('-*- CaptivePortalDetector component: ' + s + '\n');
   };
 } else {
-  debug = function (s) {};
+  debug = function(s) {};
 }
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([CaptivePortalDetector]);
--- a/toolkit/components/captivedetect/test/unit/test_captive_portal_found_303.js
+++ b/toolkit/components/captivedetect/test/unit/test_captive_portal_found_303.js
@@ -35,17 +35,17 @@ function fakeUIResponse() {
       loginFinished = true;
       do_check_eq(++step, 2);
     }
   }, 'captive-portal-login', false);
 
   Services.obs.addObserver(function observe(subject, topic, data) {
     if (topic === 'captive-portal-login-success') {
       do_check_eq(++step, 4);
-      gServer.stop(function () {
+      gServer.stop(function() {
         gRedirectServer.stop(do_test_finished);
       });
     }
   }, 'captive-portal-login-success', false);
 }
 
 function test_portal_found() {
   do_test_pending();
--- a/toolkit/components/contentprefs/ContentPrefService2.jsm
+++ b/toolkit/components/contentprefs/ContentPrefService2.jsm
@@ -217,17 +217,17 @@ ContentPrefService2.prototype = {
     group = this._parseGroup(group);
     checkNameArg(name);
 
     let storesToCheck = [this._cache];
     if (context && context.usePrivateBrowsing)
       storesToCheck.push(this._pbStore);
 
     let outStore = new ContentPrefStore();
-    storesToCheck.forEach(function (store) {
+    storesToCheck.forEach(function(store) {
       for (let [sgroup, val] of store.match(group, name, includeSubdomains)) {
         outStore.set(sgroup, name, val);
       }
     });
 
     let prefs = [];
     for (let [sgroup, sname, val] of outStore) {
       prefs.push(new ContentPref(sgroup, sname, val));
@@ -247,17 +247,17 @@ ContentPrefService2.prototype = {
   _set: function CPS2__set(group, name, value, context, callback) {
     group = this._parseGroup(group);
     checkNameArg(name);
     checkValueArg(value);
     checkCallbackArg(callback, false);
 
     if (context && context.usePrivateBrowsing) {
       this._pbStore.set(group, name, value);
-      this._schedule(function () {
+      this._schedule(function() {
         cbHandleCompletion(callback, Ci.nsIContentPrefCallback2.COMPLETE_OK);
         this._cps._notifyPrefSet(group, name, value, context.usePrivateBrowsing);
       });
       return;
     }
 
     // Invalidate the cached value so consumers accessing the cache between now
     // and when the operation finishes don't get old data.
--- a/toolkit/components/contentprefs/tests/unit/test_bug503971.js
+++ b/toolkit/components/contentprefs/tests/unit/test_bug503971.js
@@ -2,32 +2,32 @@
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 function run_test() {
   var cps = new ContentPrefInstance(null);
 
   var uri = ContentPrefTest.getURI("http://www.example.com/");
 
-  do_check_thrown(function () { cps.setPref(uri, null, 8); });
-  do_check_thrown(function () { cps.hasPref(uri, null); });
-  do_check_thrown(function () { cps.getPref(uri, null); });
-  do_check_thrown(function () { cps.removePref(uri, null); });
-  do_check_thrown(function () { cps.getPrefsByName(null); });
-  do_check_thrown(function () { cps.removePrefsByName(null); });
+  do_check_thrown(function() { cps.setPref(uri, null, 8); });
+  do_check_thrown(function() { cps.hasPref(uri, null); });
+  do_check_thrown(function() { cps.getPref(uri, null); });
+  do_check_thrown(function() { cps.removePref(uri, null); });
+  do_check_thrown(function() { cps.getPrefsByName(null); });
+  do_check_thrown(function() { cps.removePrefsByName(null); });
 
-  do_check_thrown(function () { cps.setPref(uri, "", 21); });
-  do_check_thrown(function () { cps.hasPref(uri, ""); });
-  do_check_thrown(function () { cps.getPref(uri, ""); });
-  do_check_thrown(function () { cps.removePref(uri, ""); });
-  do_check_thrown(function () { cps.getPrefsByName(""); });
-  do_check_thrown(function () { cps.removePrefsByName(""); });
+  do_check_thrown(function() { cps.setPref(uri, "", 21); });
+  do_check_thrown(function() { cps.hasPref(uri, ""); });
+  do_check_thrown(function() { cps.getPref(uri, ""); });
+  do_check_thrown(function() { cps.removePref(uri, ""); });
+  do_check_thrown(function() { cps.getPrefsByName(""); });
+  do_check_thrown(function() { cps.removePrefsByName(""); });
 }
 
-function do_check_thrown (aCallback) {
+function do_check_thrown(aCallback) {
   var exThrown = false;
   try {
     aCallback();
     do_throw("NS_ERROR_ILLEGAL_VALUE should have been thrown here");
   } catch (e) {
     do_check_eq(e.result, Cr.NS_ERROR_ILLEGAL_VALUE);
     exThrown = true;
   }
--- a/toolkit/components/contentprefs/tests/unit/test_contentPrefsCache.js
+++ b/toolkit/components/contentprefs/tests/unit/test_contentPrefsCache.js
@@ -39,17 +39,17 @@ function testCacheWorks(uri, prefName) {
   let dbValue = selectValue("SELECT value FROM prefs WHERE id = :param1", "value", prefId);
   let cacheValue = cps.getPref(uri, prefName);
 
   do_check_eq(dbValue, NEW_VALUE);
   do_check_eq(cacheValue, CACHED_VALUE);
   do_check_neq(cacheValue, dbValue);
 
   do_test_pending();
-  cps.getPref(uri, prefName, function (value) {
+  cps.getPref(uri, prefName, function(value) {
     do_check_eq(dbValue, NEW_VALUE);
     do_check_eq(value, CACHED_VALUE);
     do_check_neq(value, dbValue);
     do_test_finished();
   });
 }
 
 function testHasCachedPrefFunction(uri, prefName) {
--- a/toolkit/components/contentprefs/tests/unit/test_stringGroups.js
+++ b/toolkit/components/contentprefs/tests/unit/test_stringGroups.js
@@ -19,21 +19,21 @@ function run_test() {
 
   {
     // First check that all the methods work or don't work.
     function simple_test_methods(aGroup, shouldThrow) {
       var prefName = "test.pref.0";
       var prefValue = Math.floor(Math.random() * 100);
 
       if (shouldThrow) {
-        do_check_thrown(function () { cps.getPref(aGroup, prefName); });
-        do_check_thrown(function () { cps.setPref(aGroup, prefName, prefValue); });
-        do_check_thrown(function () { cps.hasPref(aGroup, prefName); });
-        do_check_thrown(function () { cps.removePref(aGroup, prefName); });
-        do_check_thrown(function () { cps.getPrefs(aGroup); });
+        do_check_thrown(function() { cps.getPref(aGroup, prefName); });
+        do_check_thrown(function() { cps.setPref(aGroup, prefName, prefValue); });
+        do_check_thrown(function() { cps.hasPref(aGroup, prefName); });
+        do_check_thrown(function() { cps.removePref(aGroup, prefName); });
+        do_check_thrown(function() { cps.getPrefs(aGroup); });
       } else {
         do_check_eq(cps.setPref(aGroup, prefName, prefValue), undefined);
         do_check_true(cps.hasPref(aGroup, prefName));
         do_check_eq(cps.getPref(aGroup, prefName), prefValue);
         do_check_eq(cps.removePref(aGroup, prefName), undefined);
         do_check_false(cps.hasPref(aGroup, prefName));
       }
     }
@@ -93,17 +93,17 @@ function run_test() {
     do_check_eq(cps.setPref(stringURI, "test.3", 3), undefined);
 
     enumerateAndCheck(cps.getPrefs(uri), 15, ["test.0", "test.1", "test.2", "test.3", "test.4", "test.5"]);
     enumerateAndCheck(cps.getPrefs(stringURI), 15, ["test.0", "test.1", "test.2", "test.3", "test.4", "test.5"]);
     enumerateAndCheck(cps.getPrefs(stringObjectURI), 15, ["test.0", "test.1", "test.2", "test.3", "test.4", "test.5"]);
   }
 }
 
-function do_check_thrown (aCallback) {
+function do_check_thrown(aCallback) {
   var exThrown = false;
   try {
     aCallback();
     do_throw("NS_ERROR_ILLEGAL_VALUE should have been thrown here");
   } catch (e) {
     do_check_eq(e.result, Cr.NS_ERROR_ILLEGAL_VALUE);
     exThrown = true;
   }
--- a/toolkit/components/contentprefs/tests/unit_cps2/head.js
+++ b/toolkit/components/contentprefs/tests/unit_cps2/head.js
@@ -20,28 +20,28 @@ function runAsyncTests(tests, dontResetB
 
   cps = Cc["@mozilla.org/content-pref/service;1"].
         getService(Ci.nsIContentPrefService2);
 
   let s = {};
   Cu.import("resource://test/AsyncRunner.jsm", s);
   asyncRunner = new s.AsyncRunner({
     done: do_test_finished,
-    error: function (err) {
+    error: function(err) {
       // xpcshell test functions like equal throw NS_ERROR_ABORT on
       // failure.  Ignore those and catch only uncaught exceptions.
       if (err !== Cr.NS_ERROR_ABORT) {
         if (err.stack) {
           err = err + "\n\nTraceback (most recent call first):\n" + err.stack +
                       "\nUseless do_throw stack:";
         }
         do_throw(err);
       }
     },
-    consoleError: function (scriptErr) {
+    consoleError: function(scriptErr) {
       // Previously, this code checked for console errors related to the test,
       // and treated them as failures. This was problematic, because our current
       // very-broken exception reporting machinery in XPCWrappedJSClass reports
       // errors to the console even if there's actually JS on the stack above
       // that will catch them. And a lot of the tests here intentionally trigger
       // error conditions on the JS-implemented XPCOM component (see erroneous()
       // in test_getSubdomains.js, for example). In the old world, we got lucky,
       // and the errors were never reported to the console due to happenstantial
@@ -51,22 +51,22 @@ function runAsyncTests(tests, dontResetB
       // don't turn them into duplicate failures of the exception that was already
       // propagated to the caller.
       dump("AsyncRunner.jsm observed console error: " +  scriptErr + "\n");
     }
   });
 
   next = asyncRunner.next.bind(asyncRunner);
 
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     asyncRunner.destroy();
     asyncRunner = null;
   });
 
-  tests.forEach(function (test) {
+  tests.forEach(function(test) {
     function* gen() {
       do_print("Running " + test.name);
       yield test();
       yield reset();
     }
     asyncRunner.appendIterator(gen());
   });
 
@@ -76,27 +76,27 @@ function runAsyncTests(tests, dontResetB
   } else {
     reset();
   }
 }
 
 function makeCallback(callbacks, success = null) {
   callbacks = callbacks || {};
   if (!callbacks.handleError) {
-    callbacks.handleError = function (error) {
+    callbacks.handleError = function(error) {
       do_throw("handleError call was not expected, error: " + error);
     };
   }
   if (!callbacks.handleResult) {
     callbacks.handleResult = function() {
       do_throw("handleResult call was not expected");
     };
   }
   if (!callbacks.handleCompletion)
-    callbacks.handleCompletion = function (reason) {
+    callbacks.handleCompletion = function(reason) {
       equal(reason, Ci.nsIContentPrefCallback2.COMPLETE_OK);
       if (success) {
         success();
       } else {
         next();
       }
     };
   return callbacks;
@@ -133,20 +133,20 @@ function setWithDate(group, name, val, t
         settingID = (SELECT id FROM settings WHERE name = :name)
         AND groupID = (SELECT id FROM groups WHERE name = :group)
     `);
     stmt.params.timestamp = timestamp / 1000;
     stmt.params.name = name;
     stmt.params.group = group;
 
     stmt.executeAsync({
-      handleCompletion: function (reason) {
+      handleCompletion: function(reason) {
         next();
       },
-      handleError: function (err) {
+      handleError: function(err) {
         do_throw(err);
       }
     });
     stmt.finalize();
   }
 
   cps.set(group, name, val, context, makeCallback(null, updateDate));
 }
@@ -159,24 +159,24 @@ function getDate(group, name, context) {
       settingID = (SELECT id FROM settings WHERE name = :name)
       AND groupID = (SELECT id FROM groups WHERE name = :group)
   `);
   stmt.params.name = name;
   stmt.params.group = group;
 
   let res;
   stmt.executeAsync({
-    handleResult: function (results) {
+    handleResult: function(results) {
       let row = results.getNextRow();
       res = row.getResultByName("timestamp");
     },
-    handleCompletion: function (reason) {
+    handleCompletion: function(reason) {
       next(res * 1000);
     },
-    handleError: function (err) {
+    handleError: function(err) {
       do_throw(err);
     }
   });
   stmt.finalize();
 }
 
 function set(group, name, val, context) {
   cps.set(group, name, val, context, makeCallback());
@@ -204,17 +204,17 @@ function* getOK(args, expectedVal, expec
                          name: args[1],
                          value: expectedVal }];
   yield getOKEx("getByDomainAndName", args, expectedPrefs, strict);
 }
 
 function* getSubdomainsOK(args, expectedGroupValPairs) {
   if (args.length == 2)
     args.push(undefined);
-  let expectedPrefs = expectedGroupValPairs.map(function ([group, val]) {
+  let expectedPrefs = expectedGroupValPairs.map(function([group, val]) {
     return { domain: group, name: args[1], value: val };
   });
   yield getOKEx("getBySubdomainAndName", args, expectedPrefs);
 }
 
 function* getGlobalOK(args, expectedVal) {
   if (args.length == 1)
     args.push(undefined);
@@ -224,17 +224,17 @@ function* getGlobalOK(args, expectedVal)
 }
 
 function* getOKEx(methodName, args, expectedPrefs, strict, context) {
   let actualPrefs = [];
   args.push(makeCallback({
     handleResult: pref => actualPrefs.push(pref)
   }));
   yield cps[methodName].apply(cps, args);
-  arraysOfArraysOK([actualPrefs], [expectedPrefs], function (actual, expected) {
+  arraysOfArraysOK([actualPrefs], [expectedPrefs], function(actual, expected) {
     prefOK(actual, expected, strict);
   });
 }
 
 function getCachedOK(args, expectedIsCached, expectedVal, expectedGroup,
                      strict) {
   if (args.length == 2)
     args.push(undefined);
@@ -247,21 +247,21 @@ function getCachedOK(args, expectedIsCac
 }
 
 function getCachedSubdomainsOK(args, expectedGroupValPairs) {
   if (args.length == 2)
     args.push(undefined);
   let len = {};
   args.push(len);
   let actualPrefs = cps.getCachedBySubdomainAndName.apply(cps, args);
-  actualPrefs = actualPrefs.sort(function (a, b) {
+  actualPrefs = actualPrefs.sort(function(a, b) {
     return a.domain.localeCompare(b.domain);
   });
   equal(actualPrefs.length, len.value);
-  let expectedPrefs = expectedGroupValPairs.map(function ([group, val]) {
+  let expectedPrefs = expectedGroupValPairs.map(function([group, val]) {
     return { domain: group, name: args[1], value: val };
   });
   arraysOfArraysOK([actualPrefs], [expectedPrefs], prefOK);
 }
 
 function getCachedGlobalOK(args, expectedIsCached, expectedVal) {
   if (args.length == 1)
     args.push(undefined);
@@ -280,26 +280,26 @@ function getCachedOKEx(methodName, args,
   else
     strictEqual(actualPref, null);
 }
 
 function arraysOK(actual, expected, cmp) {
   if (actual.length != expected.length) {
     do_throw("Length is not equal: " + JSON.stringify(actual) + "==" + JSON.stringify(expected));
   } else {
-    actual.forEach(function (actualElt, j) {
+    actual.forEach(function(actualElt, j) {
       let expectedElt = expected[j];
       cmp(actualElt, expectedElt);
     });
   }
 }
 
 function arraysOfArraysOK(actual, expected, cmp) {
   cmp = cmp || equal;
-  arraysOK(actual, expected, function (act, exp) {
+  arraysOK(actual, expected, function(act, exp) {
     arraysOK(act, exp, cmp)
   });
 }
 
 function dbOK(expectedRows) {
   let db = sendMessage("db");
   let stmt = db.createAsyncStatement(`
     SELECT groups.name AS grp, settings.name AS name, prefs.value AS value
@@ -331,60 +331,60 @@ function dbOK(expectedRows) {
 
     ORDER BY value ASC, grp ASC, name ASC
   `);
 
   let actualRows = [];
   let cols = ["grp", "name", "value"];
 
   db.executeAsync([stmt], 1, {
-    handleCompletion: function (reason) {
+    handleCompletion: function(reason) {
       arraysOfArraysOK(actualRows, expectedRows);
       next();
     },
-    handleResult: function (results) {
+    handleResult: function(results) {
       let row = null;
       while (row = results.getNextRow()) {
         actualRows.push(cols.map(c => row.getResultByName(c)));
       }
     },
-    handleError: function (err) {
+    handleError: function(err) {
       do_throw(err);
     }
   });
   stmt.finalize();
 }
 
 function on(event, names, dontRemove) {
   let args = {
-    reset: function () {
+    reset: function() {
       for (let prop in this) {
         if (Array.isArray(this[prop]))
           this[prop].splice(0, this[prop].length);
       }
     },
   };
 
   let observers = {};
 
-  names.forEach(function (name) {
+  names.forEach(function(name) {
     let obs = {};
-    ["onContentPrefSet", "onContentPrefRemoved"].forEach(function (meth) {
+    ["onContentPrefSet", "onContentPrefRemoved"].forEach(function(meth) {
       obs[meth] = () => do_throw(meth + " should not be called");
     });
-    obs["onContentPref" + event] = function () {
+    obs["onContentPref" + event] = function() {
       args[name].push(Array.slice(arguments));
     };
     observers[name] = obs;
     args[name] = [];
     args[name].observer = obs;
     cps.addObserverForName(name, obs);
   });
 
-  do_execute_soon(function () {
+  do_execute_soon(function() {
     if (!dontRemove)
       names.forEach(n => cps.removeObserverForName(n, observers[n]));
     next(args);
   });
 }
 
 function schemaVersionIs(expectedVersion) {
   let db = sendMessage("db");
--- a/toolkit/components/contentprefs/tests/unit_cps2/test_setGet.js
+++ b/toolkit/components/contentprefs/tests/unit_cps2/test_setGet.js
@@ -138,32 +138,32 @@ var tests = [
     // (1) Set a pref and wait for it to finish.
     yield set("a.com", "foo", 1);
 
     // (2) It should be cached.
     getCachedOK(["a.com", "foo"], true, 1);
 
     // (3) Set the pref to a new value but don't wait for it to finish.
     cps.set("a.com", "foo", 2, null, {
-      handleCompletion: function () {
+      handleCompletion: function() {
         // (6) The pref should be cached after setting it.
         getCachedOK(["a.com", "foo"], true, 2);
       },
     });
 
     // (4) Group "a.com" and name "foo" should no longer be cached.
     getCachedOK(["a.com", "foo"], false);
 
     // (5) Call getByDomainAndName.
     var fetchedPref;
     cps.getByDomainAndName("a.com", "foo", null, {
-      handleResult: function (pref) {
+      handleResult: function(pref) {
         fetchedPref = pref;
       },
-      handleCompletion: function () {
+      handleCompletion: function() {
         // (7) Finally, this callback should be called after set's above.
         do_check_true(!!fetchedPref);
         do_check_eq(fetchedPref.value, 2);
         next();
       },
     });
 
     yield;
--- a/toolkit/components/contextualidentity/ContextualIdentityService.jsm
+++ b/toolkit/components/contextualidentity/ContextualIdentityService.jsm
@@ -11,21 +11,21 @@ Cu.import("resource://gre/modules/Servic
 
 const DEFAULT_TAB_COLOR = "#909090";
 const SAVE_DELAY_MS = 1500;
 
 XPCOMUtils.defineLazyGetter(this, "gBrowserBundle", function() {
   return Services.strings.createBundle("chrome://browser/locale/browser.properties");
 });
 
-XPCOMUtils.defineLazyGetter(this, "gTextDecoder", function () {
+XPCOMUtils.defineLazyGetter(this, "gTextDecoder", function() {
   return new TextDecoder();
 });
 
-XPCOMUtils.defineLazyGetter(this, "gTextEncoder", function () {
+XPCOMUtils.defineLazyGetter(this, "gTextEncoder", function() {
   return new TextEncoder();
 });
 
 XPCOMUtils.defineLazyModuleGetter(this, "AsyncShutdown",
                                   "resource://gre/modules/AsyncShutdown.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "OS",
                                   "resource://gre/modules/osfile.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "DeferredTask",
--- a/toolkit/components/crashes/CrashManager.jsm
+++ b/toolkit/components/crashes/CrashManager.jsm
@@ -63,17 +63,17 @@ function dateToDays(date) {
  *
  *   storeDir (string)
  *     Directory we will use for our data store. This instance will write
  *     data files into the directory specified.
  *
  *   telemetryStoreSizeKey (string)
  *     Telemetry histogram to report store size under.
  */
-this.CrashManager = function (options) {
+this.CrashManager = function(options) {
   for (let k of ["pendingDumpsDir", "submittedDumpsDir", "eventsDirs",
     "storeDir"]) {
     if (!(k in options)) {
       throw new Error("Required key not present in options: " + k);
     }
   }
 
   this._log = Log.repository.getLogger("Crashes.CrashManager");
@@ -186,17 +186,17 @@ this.CrashManager.prototype = Object.fre
    *   date (Date)
    *      When this dump was created
    *
    * The returned arry is sorted by the modified time of the file backing
    * the entry, oldest to newest.
    *
    * @return Promise<Array>
    */
-  pendingDumps: function () {
+  pendingDumps: function() {
     return this._getDirectoryEntries(this._pendingDumpsDir, this.DUMP_REGEX);
   },
 
   /**
    * Obtain a list of all dump files corresponding to submitted crashes.
    *
    * The returned value is a promise that resolves to an Array of
    * objects. Each object has the following properties:
@@ -210,17 +210,17 @@ this.CrashManager.prototype = Object.fre
    *   date (Date)
    *     The (estimated) date this crash was submitted.
    *
    * The returned array is sorted by the modified time of the file backing
    * the entry, oldest to newest.
    *
    * @return Promise<Array>
    */
-  submittedDumps: function () {
+  submittedDumps: function() {
     return this._getDirectoryEntries(this._submittedDumpsDir,
                                      this.SUBMITTED_REGEX);
   },
 
   /**
    * Aggregates "loose" events files into the unified "database."
    *
    * This function should be called periodically to collect metadata from
@@ -230,17 +230,17 @@ this.CrashManager.prototype = Object.fre
    * source files are deleted.
    *
    * Only one aggregation operation is allowed to occur at a time. If this
    * is called when an existing aggregation is in progress, the promise for
    * the original call will be returned.
    *
    * @return promise<int> The number of event files that were examined.
    */
-  aggregateEventsFiles: function () {
+  aggregateEventsFiles: function() {
     if (this._aggregatePromise) {
       return this._aggregatePromise;
     }
 
     return this._aggregatePromise = Task.spawn(function* () {
       if (this._aggregatePromise) {
         return this._aggregatePromise;
       }
@@ -313,43 +313,43 @@ this.CrashManager.prototype = Object.fre
 
   /**
    * Prune old crash data.
    *
    * @param date
    *        (Date) The cutoff point for pruning. Crashes without data newer
    *        than this will be pruned.
    */
-  pruneOldCrashes: function (date) {
+  pruneOldCrashes: function(date) {
     return Task.spawn(function* () {
       let store = yield this._getStore();
       store.pruneOldCrashes(date);
       yield store.save();
     }.bind(this));
   },
 
   /**
    * Run tasks that should be periodically performed.
    */
-  runMaintenanceTasks: function () {
+  runMaintenanceTasks: function() {
     return Task.spawn(function* () {
       yield this.aggregateEventsFiles();
 
       let offset = this.PURGE_OLDER_THAN_DAYS * MILLISECONDS_IN_DAY;
       yield this.pruneOldCrashes(new Date(Date.now() - offset));
     }.bind(this));
   },
 
   /**
    * Schedule maintenance tasks for some point in the future.
    *
    * @param delay
    *        (integer) Delay in milliseconds when maintenance should occur.
    */
-  scheduleMaintenance: function (delay) {
+  scheduleMaintenance: function(delay) {
     let deferred = Promise.defer();
 
     setTimeout(() => {
       this.runMaintenanceTasks().then(deferred.resolve, deferred.reject);
     }, delay);
 
     return deferred.promise;
   },
@@ -363,17 +363,17 @@ this.CrashManager.prototype = Object.fre
    * @param processType (string) One of the PROCESS_TYPE constants.
    * @param crashType (string) One of the CRASH_TYPE constants.
    * @param id (string) Crash ID. Likely a UUID.
    * @param date (Date) When the crash occurred.
    * @param metadata (dictionary) Crash metadata, may be empty.
    *
    * @return promise<null> Resolved when the store has been saved.
    */
-  addCrash: function (processType, crashType, id, date, metadata) {
+  addCrash: function(processType, crashType, id, date, metadata) {
     return Task.spawn(function* () {
       let store = yield this._getStore();
       if (store.addCrash(processType, crashType, id, date, metadata)) {
         yield store.save();
       }
     }.bind(this));
   },
 
@@ -449,34 +449,34 @@ this.CrashManager.prototype = Object.fre
     }
   }),
 
   /**
    * Obtain the paths of all unprocessed events files.
    *
    * The promise-resolved array is sorted by file mtime, oldest to newest.
    */
-  _getUnprocessedEventsFiles: function () {
+  _getUnprocessedEventsFiles: function() {
     return Task.spawn(function* () {
       let entries = [];
 
       for (let dir of this._eventsDirs) {
         for (let e of yield this._getDirectoryEntries(dir, this.ALL_REGEX)) {
           entries.push(e);
         }
       }
 
       entries.sort((a, b) => { return a.date - b.date; });
 
       return entries;
     }.bind(this));
   },
 
   // See docs/crash-events.rst for the file format specification.
-  _processEventFile: function (entry) {
+  _processEventFile: function(entry) {
     return Task.spawn(function* () {
       let data = yield OS.File.read(entry.path);
       let store = yield this._getStore();
 
       let decoder = new TextDecoder();
       data = decoder.decode(data);
 
       let type, time;
@@ -505,17 +505,17 @@ this.CrashManager.prototype = Object.fre
       }
       let date = new Date(time * 1000);
       let payload = data.substring(start);
 
       return this._handleEventFilePayload(store, entry, type, date, payload);
     }.bind(this));
   },
 
-  _handleEventFilePayload: function (store, entry, type, date, payload) {
+  _handleEventFilePayload: function(store, entry, type, date, payload) {
       // The payload types and formats are documented in docs/crash-events.rst.
       // Do not change the format of an existing type. Instead, invent a new
       // type.
       // DO NOT ADD NEW TYPES WITHOUT DOCUMENTING!
       let lines = payload.split("\n");
 
       switch (type) {
         case "crash.main.1":
@@ -604,17 +604,17 @@ this.CrashManager.prototype = Object.fre
 
   /**
    * The resolved promise is an array of objects with the properties:
    *
    *   path -- String filename
    *   id -- regexp.match()[1] (likely the crash ID)
    *   date -- Date mtime of the file
    */
-  _getDirectoryEntries: function (path, re) {
+  _getDirectoryEntries: function(path, re) {
     return Task.spawn(function* () {
       try {
         yield OS.File.stat(path);
       } catch (ex) {
         if (!(ex instanceof OS.File.Error) || !ex.becauseNoSuchFile) {
           throw ex;
         }
         return [];
@@ -647,17 +647,17 @@ this.CrashManager.prototype = Object.fre
       }
 
       entries.sort((a, b) => { return a.date - b.date; });
 
       return entries;
     }.bind(this));
   },
 
-  _getStore: function () {
+  _getStore: function() {
     if (this._getStoreTask) {
       return this._getStoreTask;
     }
 
     return this._getStoreTask = Task.spawn(function* () {
       try {
         if (!this._store) {
           yield OS.File.makeDir(this._storeDir, {
@@ -678,17 +678,17 @@ this.CrashManager.prototype = Object.fre
         // store. Since the store takes up resources, we automatically "free"
         // the store after inactivity so resources can be returned to the
         // system. We do this via a timer and a mechanism that tracks when the
         // store is being accessed.
         this._storeTimer.cancel();
 
         // This callback frees resources from the store unless the store
         // is protected from freeing by some other process.
-        let timerCB = function () {
+        let timerCB = function() {
           if (this._storeProtectedCount) {
             this._storeTimer.initWithCallback(timerCB, this.STORE_EXPIRATION_MS,
                                               this._storeTimer.TYPE_ONE_SHOT);
             return;
           }
 
           // We kill the reference that we hold. GC will kill it later. If
           // someone else holds a reference, that will prevent GC until that
@@ -707,25 +707,25 @@ this.CrashManager.prototype = Object.fre
     }.bind(this));
   },
 
   /**
    * Obtain information about all known crashes.
    *
    * Returns an array of CrashRecord instances. Instances are read-only.
    */
-  getCrashes: function () {
+  getCrashes: function() {
     return Task.spawn(function* () {
       let store = yield this._getStore();
 
       return store.crashes;
     }.bind(this));
   },
 
-  getCrashCountsByDay: function () {
+  getCrashCountsByDay: function() {
     return Task.spawn(function* () {
       let store = yield this._getStore();
 
       return store._countsByDay;
     }.bind(this));
   },
 });
 
@@ -792,17 +792,17 @@ CrashStore.prototype = Object.freeze({
     this._countsByDay = new Map();
   },
 
   /**
    * Load data from disk.
    *
    * @return Promise
    */
-  load: function () {
+  load: function() {
     return Task.spawn(function* () {
       // Loading replaces data.
       this.reset();
 
       try {
         let decoder = new TextDecoder();
         let data = yield OS.File.read(this._storePath, {compression: "lz4"});
         data = JSON.parse(decoder.decode(data));
@@ -892,17 +892,17 @@ CrashStore.prototype = Object.freeze({
     }.bind(this));
   },
 
   /**
    * Save data to disk.
    *
    * @return Promise<null>
    */
-  save: function () {
+  save: function() {
     return Task.spawn(function* () {
       if (!this._data) {
         return;
       }
 
       let normalized = {
         // The version should be incremented whenever the format
         // changes.
@@ -962,17 +962,17 @@ CrashStore.prototype = Object.freeze({
    * This function along with _denormalize() serve to hack around the
    * default handling of Date JSON serialization because Date serialization
    * is undefined by JSON.
    *
    * Fields ending with "Date" are assumed to contain Date instances.
    * We convert these to milliseconds since epoch on output and back to
    * Date on input.
    */
-  _normalize: function (o) {
+  _normalize: function(o) {
     let normalized = {};
 
     for (let k in o) {
       let v = o[k];
       if (v && k.endsWith("Date")) {
         normalized[k] = v.getTime();
       } else {
         normalized[k] = v;
@@ -980,17 +980,17 @@ CrashStore.prototype = Object.freeze({
     }
 
     return normalized;
   },
 
   /**
    * Convert a serialized object back to its native form.
    */
-  _denormalize: function (o) {
+  _denormalize: function(o) {
     let n = {};
 
     for (let k in o) {
       let v = o[k];
       if (v && k.endsWith("Date")) {
         n[k] = new Date(parseInt(v, 10));
       } else {
         n[k] = v;
@@ -1006,17 +1006,17 @@ CrashStore.prototype = Object.freeze({
    * Crashes without recent activity are pruned from the store so the
    * size of the store is not unbounded. If there is activity on a crash,
    * that activity will keep the crash and all its data around for longer.
    *
    * @param date
    *        (Date) The cutoff at which data will be pruned. If an entry
    *        doesn't have data newer than this, it will be pruned.
    */
-  pruneOldCrashes: function (date) {
+  pruneOldCrashes: function(date) {
     for (let crash of this.crashes) {
       let newest = crash.newestDate;
       if (!newest || newest.getTime() < date.getTime()) {
         this._data.crashes.delete(crash.id);
       }
     }
   },
 
@@ -1051,27 +1051,27 @@ CrashStore.prototype = Object.freeze({
   },
 
   /**
    * Obtain a particular crash from its ID.
    *
    * A CrashRecord will be returned if the crash exists. null will be returned
    * if the crash is unknown.
    */
-  getCrash: function (id) {
+  getCrash: function(id) {
     for (let crash of this.crashes) {
       if (crash.id == id) {
         return crash;
       }
     }
 
     return null;
   },
 
-  _ensureCountsForDay: function (day) {
+  _ensureCountsForDay: function(day) {
     if (!this._countsByDay.has(day)) {
       this._countsByDay.set(day, new Map());
     }
   },
 
   /**
    * Ensure the crash record is present in storage.
    *
@@ -1086,17 +1086,17 @@ CrashStore.prototype = Object.freeze({
    *        (string) The crash ID.
    * @param date
    *        (Date) When this crash occurred.
    * @param metadata
    *        (dictionary) Crash metadata, may be empty.
    *
    * @return null | object crash record
    */
-  _ensureCrashRecord: function (processType, crashType, id, date, metadata) {
+  _ensureCrashRecord: function(processType, crashType, id, date, metadata) {
     if (!id) {
       // Crashes are keyed on ID, so it's not really helpful to store crashes
       // without IDs.
       return null;
     }
 
     let type = processType + "-" + crashType;
 
@@ -1144,49 +1144,49 @@ CrashStore.prototype = Object.freeze({
    * @param processType (string) One of the PROCESS_TYPE constants.
    * @param crashType (string) One of the CRASH_TYPE constants.
    * @param id (string) Crash ID. Likely a UUID.
    * @param date (Date) When the crash occurred.
    * @param metadata (dictionary) Crash metadata, may be empty.
    *
    * @return boolean True if the crash was recorded and false if not.
    */
-  addCrash: function (processType, crashType, id, date, metadata) {
+  addCrash: function(processType, crashType, id, date, metadata) {
     return !!this._ensureCrashRecord(processType, crashType, id, date, metadata);
   },
 
   /**
    * @return boolean True if the remote ID was recorded and false if not.
    */
-  setRemoteCrashID: function (crashID, remoteID) {
+  setRemoteCrashID: function(crashID, remoteID) {
     let crash = this._data.crashes.get(crashID);
     if (!crash || !remoteID) {
       return false;
     }
 
     crash.remoteID = remoteID;
     return true;
   },
 
-  getCrashesOfType: function (processType, crashType) {
+  getCrashesOfType: function(processType, crashType) {
     let crashes = [];
     for (let crash of this.crashes) {
       if (crash.isOfType(processType, crashType)) {
         crashes.push(crash);
       }
     }
 
     return crashes;
   },
 
   /**
    * Ensure the submission record is present in storage.
    * @returns [submission, crash]
    */
-  _ensureSubmissionRecord: function (crashID, submissionID) {
+  _ensureSubmissionRecord: function(crashID, submissionID) {
     let crash = this._data.crashes.get(crashID);
     if (!crash || !submissionID) {
       return null;
     }
 
     if (!crash.submissions.has(submissionID)) {
       crash.submissions.set(submissionID, {
         requestDate: null,
@@ -1196,33 +1196,33 @@ CrashStore.prototype = Object.freeze({
     }
 
     return [crash.submissions.get(submissionID), crash];
   },
 
   /**
    * @return boolean True if the attempt was recorded.
    */
-  addSubmissionAttempt: function (crashID, submissionID, date) {
+  addSubmissionAttempt: function(crashID, submissionID, date) {
     let [submission, crash] =
       this._ensureSubmissionRecord(crashID, submissionID);
     if (!submission) {
       return false;
     }
 
     submission.requestDate = date;
     Services.telemetry.getKeyedHistogramById("PROCESS_CRASH_SUBMIT_ATTEMPT")
       .add(crash.type, 1);
     return true;
   },
 
   /**
    * @return boolean True if the response was recorded.
    */
-  addSubmissionResult: function (crashID, submissionID, date, result) {
+  addSubmissionResult: function(crashID, submissionID, date, result) {
     let crash = this._data.crashes.get(crashID);
     if (!crash || !submissionID) {
       return false;
     }
     let submission = crash.submissions.get(submissionID);
     if (!submission) {
       return false;
     }
@@ -1232,17 +1232,17 @@ CrashStore.prototype = Object.freeze({
     Services.telemetry.getKeyedHistogramById("PROCESS_CRASH_SUBMIT_SUCCESS")
       .add(crash.type, result == "ok");
     return true;
   },
 
   /**
    * @return boolean True if the classifications were set.
    */
-  setCrashClassifications: function (crashID, classifications) {
+  setCrashClassifications: function(crashID, classifications) {
     let crash = this._data.crashes.get(crashID);
     if (!crash) {
       return false;
     }
 
     crash.classifications = classifications;
     return true;
   },
@@ -1291,17 +1291,17 @@ CrashRecord.prototype = Object.freeze({
   get oldestDate() {
     return this._o.crashDate;
   },
 
   get type() {
     return this._o.type;
   },
 
-  isOfType: function (processType, crashType) {
+  isOfType: function(processType, crashType) {
     return processType + "-" + crashType == this.type;
   },
 
   get submissions() {
     return this._o.submissions;
   },
 
   get classifications() {
@@ -1314,17 +1314,17 @@ CrashRecord.prototype = Object.freeze({
 });
 
 /**
  * Obtain the global CrashManager instance used by the running application.
  *
  * CrashManager is likely only ever instantiated once per application lifetime.
  * The main reason it's implemented as a reusable type is to facilitate testing.
  */
-XPCOMUtils.defineLazyGetter(this.CrashManager, "Singleton", function () {
+XPCOMUtils.defineLazyGetter(this.CrashManager, "Singleton", function() {
   if (gCrashManager) {
     return gCrashManager;
   }
 
   let crPath = OS.Path.join(OS.Constants.Path.userApplicationDataDir,
                             "Crash Reports");
   let storePath = OS.Path.join(OS.Constants.Path.profileDir, "crashes");
 
--- a/toolkit/components/crashes/CrashManagerTest.jsm
+++ b/toolkit/components/crashes/CrashManagerTest.jsm
@@ -22,47 +22,47 @@ Cu.import("resource://gre/modules/CrashM
 Cu.import("resource://gre/modules/Log.jsm", this);
 Cu.import("resource://gre/modules/osfile.jsm", this);
 Cu.import("resource://gre/modules/Promise.jsm", this);
 Cu.import("resource://gre/modules/Task.jsm", this);
 Cu.import("resource://gre/modules/Timer.jsm", this);
 
 var loggingConfigured = false;
 
-this.configureLogging = function () {
+this.configureLogging = function() {
   if (loggingConfigured) {
     return;
   }
 
   let log = Log.repository.getLogger("Crashes.CrashManager");
   log.level = Log.Level.All;
   let appender = new Log.DumpAppender();
   appender.level = Log.Level.All;
   log.addAppender(appender);
   loggingConfigured = true;
 };
 
-this.sleep = function (wait) {
+this.sleep = function(wait) {
   let deferred = Promise.defer();
 
   setTimeout(() => {
     deferred.resolve();
   }, wait);
 
   return deferred.promise;
 };
 
-this.TestingCrashManager = function (options) {
+this.TestingCrashManager = function(options) {
   CrashManager.call(this, options);
 }
 
 this.TestingCrashManager.prototype = {
   __proto__: CrashManager.prototype,
 
-  createDummyDump: function (submitted = false, date = new Date(), hr = false) {
+  createDummyDump: function(submitted = false, date = new Date(), hr = false) {
     let uuid = Cc["@mozilla.org/uuid-generator;1"]
                 .getService(Ci.nsIUUIDGenerator)
                 .generateUUID()
                 .toString();
     uuid = uuid.substring(1, uuid.length - 1);
 
     let path;
     let mode;
@@ -84,32 +84,32 @@ this.TestingCrashManager.prototype = {
       yield f.setDates(date, date);
       yield f.close();
       dump("Created fake crash: " + path + "\n");
 
       return uuid;
     });
   },
 
-  createIgnoredDumpFile: function (filename, submitted = false) {
+  createIgnoredDumpFile: function(filename, submitted = false) {
     let path;
     if (submitted) {
       path = OS.Path.join(this._submittedDumpsDir, filename);
     } else {
       path = OS.Path.join(this._pendingDumpsDir, filename);
     }
 
     return Task.spawn(function* () {
       let mode = OS.Constants.libc.S_IRUSR | OS.Constants.libc.S_IWUSR;
       yield OS.File.open(path, {create: true}, {unixMode: mode});
       dump("Create ignored dump file: " + path + "\n");
     });
   },
 
-  createEventsFile: function (filename, type, date, content, index = 0) {
+  createEventsFile: function(filename, type, date, content, index = 0) {
     let path = OS.Path.join(this._eventsDirs[index], filename);
 
     let data = type + "\n" +
                Math.floor(date.getTime() / 1000) + "\n" +
                content;
     let encoder = new TextEncoder();
     let array = encoder.encode(data);
 
@@ -119,17 +119,17 @@ this.TestingCrashManager.prototype = {
     });
   },
 
   /**
    * Overwrite event file handling to process our test file type.
    *
    * We can probably delete this once we have actual events defined.
    */
-  _handleEventFilePayload: function (store, entry, type, date, payload) {
+  _handleEventFilePayload: function(store, entry, type, date, payload) {
     if (type == "test.1") {
       if (payload == "malformed") {
         return this.EVENT_FILE_ERROR_MALFORMED;
       } else if (payload == "success") {
         return this.EVENT_FILE_SUCCESS;
       }
       return this.EVENT_FILE_ERROR_UNKNOWN_EVENT;
     }
@@ -140,17 +140,17 @@ this.TestingCrashManager.prototype = {
                                                                type,
                                                                date,
                                                                payload);
   },
 };
 
 var DUMMY_DIR_COUNT = 0;
 
-this.getManager = function () {
+this.getManager = function() {
   return Task.spawn(function* () {
     const dirMode = OS.Constants.libc.S_IRWXU;
     let baseFile = OS.Constants.Path.profileDir;
 
     function makeDir(create = true) {
       return Task.spawn(function* () {
         let path = OS.Path.join(baseFile, "dummy-dir-" + DUMMY_DIR_COUNT++);
 
--- a/toolkit/components/crashes/CrashService.js
+++ b/toolkit/components/crashes/CrashService.js
@@ -9,26 +9,26 @@ const {classes: Cc, interfaces: Ci, util
 Cu.import("resource://gre/modules/Services.jsm", this);
 Cu.import("resource://gre/modules/XPCOMUtils.jsm", this);
 
 /**
  * This component makes crash data available throughout the application.
  *
  * It is a service because some background activity will eventually occur.
  */
-this.CrashService = function () {};
+this.CrashService = function() {};
 
 CrashService.prototype = Object.freeze({
   classID: Components.ID("{92668367-1b17-4190-86b2-1061b2179744}"),
   QueryInterface: XPCOMUtils.generateQI([
     Ci.nsICrashService,
     Ci.nsIObserver,
   ]),
 
-  addCrash: function (processType, crashType, id) {
+  addCrash: function(processType, crashType, id) {
     switch (processType) {
     case Ci.nsICrashService.PROCESS_TYPE_MAIN:
       processType = Services.crashmanager.PROCESS_TYPE_MAIN;
       break;
     case Ci.nsICrashService.PROCESS_TYPE_CONTENT:
       processType = Services.crashmanager.PROCESS_TYPE_CONTENT;
       break;
     case Ci.nsICrashService.PROCESS_TYPE_PLUGIN:
@@ -53,17 +53,17 @@ CrashService.prototype = Object.freeze({
       break;
     default:
       throw new Error("Unrecognized CRASH_TYPE: " + crashType);
     }
 
     Services.crashmanager.addCrash(processType, crashType, id, new Date());
   },
 
-  observe: function (subject, topic, data) {
+  observe: function(subject, topic, data) {
     switch (topic) {
       case "profile-after-change":
         // Side-effect is the singleton is instantiated.
         Services.crashmanager;
         break;
     }
   },
 });
--- a/toolkit/components/crashmonitor/CrashMonitor.jsm
+++ b/toolkit/components/crashmonitor/CrashMonitor.jsm
@@ -88,17 +88,17 @@ var CrashMonitorInternal = {
    */
   path: OS.Path.join(OS.Constants.Path.profileDir, "sessionCheckpoints.json"),
 
   /**
    * Load checkpoints from previous session asynchronously.
    *
    * @return {Promise} A promise that resolves/rejects once loading is complete
    */
-  loadPreviousCheckpoints: function () {
+  loadPreviousCheckpoints: function() {
     this.previousCheckpoints = Task.spawn(function*() {
       let data;
       try {
         data = yield OS.File.read(CrashMonitorInternal.path, { encoding: "utf-8" });
       } catch (ex) {
         if (!(ex instanceof OS.File.Error)) {
           throw ex;
         }
@@ -150,27 +150,27 @@ this.CrashMonitor = {
 
   /**
    * Initialize CrashMonitor.
    *
    * Should only be called from the CrashMonitor XPCOM component.
    *
    * @return {Promise}
    */
-  init: function () {
+  init: function() {
     if (CrashMonitorInternal.initialized) {
       throw new Error("CrashMonitor.init() must only be called once!");
     }
 
     let promise = CrashMonitorInternal.loadPreviousCheckpoints();
     // Add "profile-after-change" to checkpoint as this method is
     // called after receiving it
     CrashMonitorInternal.checkpoints["profile-after-change"] = true;
 
-    NOTIFICATIONS.forEach(function (aTopic) {
+    NOTIFICATIONS.forEach(function(aTopic) {
       Services.obs.addObserver(this, aTopic, false);
     }, this);
 
     // Add shutdown blocker for profile-before-change
     OS.File.profileBeforeChange.addBlocker(
       "CrashMonitor: Writing notifications to file after receiving profile-before-change",
       CrashMonitorInternal.profileBeforeChangeDeferred.promise,
       () => this.checkpoints
@@ -180,17 +180,17 @@ this.CrashMonitor = {
     return promise;
   },
 
   /**
    * Handle registered notifications.
    *
    * Update checkpoint file for every new notification received.
    */
-  observe: function (aSubject, aTopic, aData) {
+  observe: function(aSubject, aTopic, aData) {
     if (!(aTopic in CrashMonitorInternal.checkpoints)) {
       // If this is the first time this notification is received,
       // remember it and write it to file
       CrashMonitorInternal.checkpoints[aTopic] = true;
       Task.spawn(function* () {
         try {
           let data = JSON.stringify(CrashMonitorInternal.checkpoints);
 
@@ -210,15 +210,15 @@ this.CrashMonitor = {
             CrashMonitorInternal.profileBeforeChangeDeferred.resolve();
           }
         }
       });
     }
 
     if (NOTIFICATIONS.every(elem => elem in CrashMonitorInternal.checkpoints)) {
       // All notifications received, unregister observers
-      NOTIFICATIONS.forEach(function (aTopic) {
+      NOTIFICATIONS.forEach(function(aTopic) {
         Services.obs.removeObserver(this, aTopic);
       }, this);
     }
   }
 };
 Object.freeze(this.CrashMonitor);
--- a/toolkit/components/crashmonitor/nsCrashMonitor.js
+++ b/toolkit/components/crashmonitor/nsCrashMonitor.js
@@ -13,17 +13,17 @@ function CrashMonitor() {}
 
 CrashMonitor.prototype = {
 
   classID: Components.ID("{d9d75e86-8f17-4c57-993e-f738f0d86d42}"),
   contractID: "@mozilla.org/toolkit/crashmonitor;1",
 
   QueryInterface: XPCOMUtils.generateQI([Components.interfaces.nsIObserver]),
 
-  observe: function (aSubject, aTopic, aData) {
+  observe: function(aSubject, aTopic, aData) {
     switch (aTopic) {
     case "profile-after-change":
       MonitorAPI.init();
     }
   },
 };
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([CrashMonitor]);
--- a/toolkit/components/ctypes/tests/unit/test_jsctypes.js
+++ b/toolkit/components/ctypes/tests/unit/test_jsctypes.js
@@ -183,28 +183,28 @@ function run_test()
   do_check_throws(function() {
     library.declare("test_void_t_cdecl", ctypes.default_abi, ctypes.void_t);
   }, Error);
 
   // test that library functions throw when bound to other objects
   library = ctypes.open(libfile.path);
   let obj = {};
   obj.declare = library.declare;
-  do_check_throws(function () { run_void_tests(obj); }, Error);
+  do_check_throws(function() { run_void_tests(obj); }, Error);
   obj.close = library.close;
-  do_check_throws(function () { obj.close(); }, Error);
+  do_check_throws(function() { obj.close(); }, Error);
 
   // test that functions work as properties of other objects
   let getter = library.declare("get_int8_t_cdecl", ctypes.default_abi, ctypes.int8_t);
   do_check_eq(getter(), 109);
   obj.t = getter;
   do_check_eq(obj.t(), 109);
 
   // bug 521937
-  do_check_throws(function () { let nolib = ctypes.open("notfoundlibrary.dll"); nolib.close(); }, Error);
+  do_check_throws(function() { let nolib = ctypes.open("notfoundlibrary.dll"); nolib.close(); }, Error);
 
   // bug 522360
   do_check_eq(run_load_system_library(), true);
 
   // Test loading a library with a unicode name (bug 589413). Note that nsIFile
   // implementations are not available in some harnesses; if not, the harness
   // should take care of the copy for us.
   let unicodefile = do_get_file(CTYPES_UNICODE_LIB, true);
@@ -408,24 +408,24 @@ function run_Int64_tests() {
   do_check_eq(int64.toString(10), "9223372036854775807");
   do_check_eq(int64.toString(16), "7fffffffffffffff");
   do_check_eq(int64.toString(2), "111111111111111111111111111111111111111111111111111111111111111");
 
   let vals = [-0x8000000000001000, 0x8000000000000000,
               ctypes.UInt64("0x8000000000000000"),
               Infinity, -Infinity, NaN, 0.1,
               5.68e21, null, undefined, "", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { ctypes.Int64(vals[i]); }, TypeError);
+    do_check_throws(function() { ctypes.Int64(vals[i]); }, TypeError);
 
   vals = ["-0x8000000000000001", "0x8000000000000000"];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { ctypes.Int64(vals[i]); }, RangeError);
+    do_check_throws(function() { ctypes.Int64(vals[i]); }, RangeError);
 
   // Test ctypes.Int64.compare.
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(5), ctypes.Int64(5)), 0);
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(5), ctypes.Int64(4)), 1);
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(4), ctypes.Int64(5)), -1);
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(-5), ctypes.Int64(-5)), 0);
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(-5), ctypes.Int64(-4)), -1);
   do_check_eq(ctypes.Int64.compare(ctypes.Int64(-4), ctypes.Int64(-5)), 1);
@@ -558,24 +558,24 @@ function run_UInt64_tests() {
   do_check_eq(uint64.toString(), uint64.toString(10));
   do_check_eq(uint64.toString(10), "9223372036854775807");
   do_check_eq(uint64.toString(16), "7fffffffffffffff");
   do_check_eq(uint64.toString(2), "111111111111111111111111111111111111111111111111111111111111111");
 
   let vals = [-1, 0x10000000000000000, "-1", "-0x1",
               ctypes.Int64("-1"), Infinity, -Infinity, NaN, 0.1,
               5.68e21, null, undefined, "", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { ctypes.UInt64(vals[i]); }, TypeError);
+    do_check_throws(function() { ctypes.UInt64(vals[i]); }, TypeError);
 
   vals = ["0x10000000000000000"];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { ctypes.UInt64(vals[i]); }, RangeError);
+    do_check_throws(function() { ctypes.UInt64(vals[i]); }, RangeError);
 
   // Test ctypes.UInt64.compare.
   do_check_eq(ctypes.UInt64.compare(ctypes.UInt64(5), ctypes.UInt64(5)), 0);
   do_check_eq(ctypes.UInt64.compare(ctypes.UInt64(5), ctypes.UInt64(4)), 1);
   do_check_eq(ctypes.UInt64.compare(ctypes.UInt64(4), ctypes.UInt64(5)), -1);
   do_check_throws(function() { ctypes.UInt64.compare(ctypes.UInt64(4), ctypes.Int64(4)); }, TypeError);
   do_check_throws(function() { ctypes.UInt64.compare(4, 5); }, TypeError);
 
@@ -773,20 +773,20 @@ function run_bool_tests(library) {
   do_check_eq(d.value, 1);
   d = new t(1);
   do_check_eq(d.value, 1);
 
   // don't convert anything else
   let vals = [-1, 2, Infinity, -Infinity, NaN, 0.1,
               ctypes.Int64(0), ctypes.UInt64(0),
               null, undefined, "", "0", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   do_check_true(d.address().constructor === t.ptr);
   do_check_eq(d.address().contents, d.value);
   do_check_eq(d.toSource(), "ctypes." + name + "(" + d.value + ")");
   do_check_eq(d.toSource(), d.toString());
 
   // Test the function call ABI for calls involving the type,
   // and check the alignment of the type against what C says.
@@ -853,20 +853,20 @@ function run_integer_tests(library, t, n
   d.value = false;
   do_check_eq(d.value, 0);
   d.value = true;
   do_check_eq(d.value, 1);
 
   // don't convert anything else
   let vals = [limits[0] - 1, limits[1] + 1, Infinity, -Infinity, NaN, 0.1,
               null, undefined, "", "0", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   do_check_true(d.address().constructor === t.ptr);
   do_check_eq(d.address().contents, d.value);
   do_check_eq(d.toSource(), "ctypes." + name + "(" + d.value + ")");
   do_check_eq(d.toSource(), d.toString());
 
   // Test the function call ABI for calls involving the type,
   // and check the alignment of the type against what C says.
@@ -940,20 +940,20 @@ function run_float_tests(library, t, nam
   do_check_true(isNaN(d.value));
   d.value = 0;
   do_check_eq(d.value, 0);
   d.value = -0;
   do_check_eq(1 / d.value, 1 / -0);
 
   // don't convert anything else
   let vals = [true, false, null, undefined, "", "0", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   // Check that values roundtrip through toSource() correctly.
   function test_roundtrip(tFn, val)
   {
     let f1 = tFn(val);
     eval("var f2 = " + f1.toSource());
     do_check_eq(f1.value, f2.value);
   }
@@ -1040,20 +1040,20 @@ function run_wrapped_integer_tests(libra
   d.value = false;
   do_check_eq(d.value, 0);
   d.value = true;
   do_check_eq(d.value, 1);
 
   // don't convert anything else
   let vals = [limits[2], limits[3], Infinity, -Infinity, NaN, 0.1,
               null, undefined, "", "0", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   do_check_true(d.address().constructor === t.ptr);
   do_check_eq(d.address().contents.toString(), d.value.toString());
   do_check_eq(d.toSource(), "ctypes." + name + "(" + wname + "(\"" + d.value + "\"))");
   do_check_eq(d.toSource(), d.toString());
 
   // Test the function call ABI for calls involving the type,
   // and check the alignment of the type against what C says.
@@ -1123,20 +1123,20 @@ function run_char_tests(library, t, name
   d.value = true;
   do_check_eq(d.value, 1);
 
   do_check_throws(function() { d.value = "5"; }, TypeError);
 
   // don't convert anything else
   let vals = [limits[0] - 1, limits[1] + 1, Infinity, -Infinity, NaN, 0.1,
               null, undefined, "", "aa", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   do_check_true(d.address().constructor === t.ptr);
   do_check_eq(d.address().contents, 1);
   do_check_eq(d.toSource(), "ctypes." + name + "(" + d.value + ")");
   do_check_eq(d.toSource(), d.toString());
 
   // Test string autoconversion (and lack thereof).
   let literal = "autoconverted";
@@ -1215,20 +1215,20 @@ function run_char16_tests(library, t, na
   d.value = "\0";
   do_check_eq(toprimitive(d.value), 0);
   d.value = "a";
   do_check_eq(d.value, "a");
 
   // don't convert anything else
   let vals = [limits[0] - 1, limits[1] + 1, Infinity, -Infinity, NaN, 0.1,
               null, undefined, "", "aa", {}, [], new Number(16),
-              {toString: function () { return 7; }},
-              {valueOf: function () { return 7; }}];
+              {toString: function() { return 7; }},
+              {valueOf: function() { return 7; }}];
   for (let i = 0; i < vals.length; i++)
-    do_check_throws(function () { d.value = vals[i]; }, TypeError);
+    do_check_throws(function() { d.value = vals[i]; }, TypeError);
 
   do_check_true(d.address().constructor === t.ptr);
   do_check_eq(d.address().contents, "a");
   do_check_eq(d.toSource(), "ctypes." + name + "(\"" + d.value + "\")");
   do_check_eq(d.toSource(), d.toString());
 
   // Test string autoconversion (and lack thereof).
   let literal = "autoconverted";
@@ -2218,17 +2218,17 @@ function run_void_tests(library) {
 }
 
 function run_string_tests(library) {
   let test_ansi_len = library.declare("test_ansi_len", ctypes.default_abi, ctypes.int32_t, ctypes.char.ptr);
   do_check_eq(test_ansi_len(""), 0);
   do_check_eq(test_ansi_len("hello world"), 11);
 
   // don't convert anything else to a string
-  let vals = [true, 0, 1 / 3, undefined, {}, {toString: function () { return "bad"; }}, []];
+  let vals = [true, 0, 1 / 3, undefined, {}, {toString: function() { return "bad"; }}, []];
   for (let i = 0; i < vals.length; i++)
     do_check_throws(function() { test_ansi_len(vals[i]); }, TypeError);
 
   let test_wide_len = library.declare("test_wide_len", ctypes.default_abi, ctypes.int32_t, ctypes.char16_t.ptr);
   do_check_eq(test_wide_len("hello world"), 11);
 
   let test_ansi_ret = library.declare("test_ansi_ret", ctypes.default_abi, ctypes.char.ptr);
   do_check_eq(test_ansi_ret().readString(), "success");
--- a/toolkit/components/downloads/test/unit/test_app_rep_windows.js
+++ b/toolkit/components/downloads/test/unit/test_app_rep_windows.js
@@ -114,18 +114,18 @@ function promiseSaverComplete(aSaver, aO
 function promiseCopyToSaver(aSourceString, aSaverOutputStream, aCloseWhenDone) {
   let deferred = Promise.defer();
   let inputStream = new StringInputStream(aSourceString, aSourceString.length);
   let copier = Cc["@mozilla.org/network/async-stream-copier;1"]
                .createInstance(Ci.nsIAsyncStreamCopier);
   copier.init(inputStream, aSaverOutputStream, null, false, true, 0x8000, true,
               aCloseWhenDone);
   copier.asyncCopy({
-    onStartRequest: function () { },
-    onStopRequest: function (aRequest, aContext, aStatusCode)
+    onStartRequest: function() { },
+    onStopRequest: function(aRequest, aContext, aStatusCode)
     {
       if (Components.isSuccessCode(aStatusCode)) {
         deferred.resolve();
       } else {
         deferred.reject(new Components.Exception(aResult));
       }
     },
   }, null);
--- a/toolkit/components/exthelper/extApplication.js
+++ b/toolkit/components/exthelper/extApplication.js
@@ -545,17 +545,17 @@ Extension.prototype = {
 };
 
 
 // =================================================
 // Extensions constructor
 function Extensions(addons) {
   this._cache = {};
 
-  addons.forEach(function (addon) {
+  addons.forEach(function(addon) {
     this._cache[addon.id] = new Extension(addon);
   }, this);
 }
 
 // =================================================
 // Extensions implementation
 Extensions.prototype = {
   get all() {
@@ -659,17 +659,17 @@ extApplication.prototype = {
 
   get prefs() {
     let prefs = new PreferenceBranch("");
     this.__defineGetter__("prefs", () => prefs);
     return this.prefs;
   },
 
   getExtensions: function(callback) {
-    AddonManager.getAddonsByTypes(["extension"], function (addons) {
+    AddonManager.getAddonsByTypes(["extension"], function(addons) {
       callback.callback(new Extensions(addons));
     });
   },
 
   get events() {
 
     // This ensures that FUEL only registers for notifications as needed
     // by callers. Note that the unload (xpcom-shutdown) event is listened
--- a/toolkit/components/filepicker/nsFilePicker.js
+++ b/toolkit/components/filepicker/nsFilePicker.js
@@ -283,19 +283,19 @@ nsFilePicker.prototype = {
       return o.retvals.buttonStatus;
     } catch (ex) { dump("unable to open file picker\n" + ex + "\n"); }
 
     return null;
   }
 }
 
 if (DEBUG)
-  debug = function (s) { dump("-*- filepicker: " + s + "\n"); };
+  debug = function(s) { dump("-*- filepicker: " + s + "\n"); };
 else
-  debug = function (s) {};
+  debug = function(s) {};
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([nsFilePicker]);
 
 /* crap from strres.js that I want to use for string bundles since I can't include another .js file.... */
 
 var strBundleService = null;
 
 function srGetStrBundle(path)
--- a/toolkit/components/formautofill/FormAutofillContentService.js
+++ b/toolkit/components/formautofill/FormAutofillContentService.js
@@ -138,17 +138,17 @@ FormHandler.prototype = {
   /**
    * Returns information from the form about fields that can be autofilled, and
    * populates the fieldDetails array on this object accordingly.
    *
    * @returns Serializable data structure that can be sent to the user
    *          interface, or null if the operation failed because the constraints
    *          on the allowed fields were not honored.
    */
-  collectFormFields: function () {
+  collectFormFields: function() {
     let autofillData = {
       sections: [],
     };
 
     for (let element of this.form.elements) {
       // Query the interface and exclude elements that cannot be autocompleted.
       if (!(element instanceof Ci.nsIDOMHTMLInputElement)) {
         continue;
@@ -220,17 +220,17 @@ FormHandler.prototype = {
    *            section: Value originally provided to the user interface.
    *            addressType: Value originally provided to the user interface.
    *            contactType: Value originally provided to the user interface.
    *            fieldName: Value originally provided to the user interface.
    *            value: String with which the field should be updated.
    *          ],
    *        }
    */
-  autofillFormFields: function (aAutofillResult) {
+  autofillFormFields: function(aAutofillResult) {
     for (let field of aAutofillResult.fields) {
       // Get the field details, if it was processed by the user interface.
       let fieldDetail = this.fieldDetails
                             .find(f => f.section == field.section &&
                                        f.addressType == field.addressType &&
                                        f.contactType == field.contactType &&
                                        f.fieldName == field.fieldName);
       if (!fieldDetail) {
@@ -239,18 +239,18 @@ FormHandler.prototype = {
 
       fieldDetail.element.value = field.value;
     }
   },
 
   /**
    * Waits for one tick of the event loop before resolving the returned promise.
    */
-  waitForTick: function () {
-    return new Promise(function (resolve) {
+  waitForTick: function() {
+    return new Promise(function(resolve) {
       Services.tm.currentThread.dispatch(resolve, Ci.nsIThread.DISPATCH_NORMAL);
     });
   },
 };
 
 /**
  * Implements a service used by DOM content to request Form Autofill, in
  * particular when the requestAutocomplete method of Form objects is invoked.
@@ -258,15 +258,15 @@ FormHandler.prototype = {
 function FormAutofillContentService() {
 }
 
 FormAutofillContentService.prototype = {
   classID: Components.ID("{ed9c2c3c-3f86-4ae5-8e31-10f71b0f19e6}"),
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIFormAutofillContentService]),
 
   // nsIFormAutofillContentService
-  requestAutocomplete: function (aForm, aWindow) {
+  requestAutocomplete: function(aForm, aWindow) {
     new FormHandler(aForm, aWindow).handleRequestAutocomplete()
                                    .catch(Cu.reportError);
   },
 };
 
 this.NSGetFactory = XPCOMUtils.generateNSGetFactory([FormAutofillContentService]);
--- a/toolkit/components/formautofill/FormAutofillStartup.js
+++ b/toolkit/components/formautofill/FormAutofillStartup.js
@@ -26,30 +26,30 @@ FormAutofillStartup.prototype = {
   classID: Components.ID("{51c95b3d-7431-467b-8d50-383f158ce9e5}"),
   QueryInterface: XPCOMUtils.generateQI([
     Ci.nsIFrameMessageListener,
     Ci.nsIObserver,
     Ci.nsISupportsWeakReference,
   ]),
 
   // nsIObserver
-  observe: function (aSubject, aTopic, aData) {
+  observe: function(aSubject, aTopic, aData) {
     // This method is called by the "profile-after-change" category on startup,
     // which is called before any web page loads.  At this time, we need to
     // register a global message listener in the parent process preemptively,
     // because we can receive requests from child processes at any time.  For
     // performance reasons, we use this object as a message listener, so that we
     // don't have to load the FormAutoFill module at startup.
     let globalMM = Cc["@mozilla.org/globalmessagemanager;1"]
                      .getService(Ci.nsIMessageListenerManager);
     globalMM.addMessageListener("FormAutofill:RequestAutocomplete", this);
   },
 
   // nsIFrameMessageListener
-  receiveMessage: function (aMessage) {
+  receiveMessage: function(aMessage) {
     // Process the "FormAutofill:RequestAutocomplete" message.  Any exception
     // raised in the parent process is caught and serialized into the reply
     // message that is sent to the requesting child process.
     FormAutofill.processRequestAutocomplete(aMessage.data)
       .catch(ex => { return { exception: ex } })
       .then(result => {
         // The browser message manager in the parent will send the reply to the
         // associated frame message manager in the child.
--- a/toolkit/components/formautofill/content/RequestAutocompleteUI.jsm
+++ b/toolkit/components/formautofill/content/RequestAutocompleteUI.jsm
@@ -20,17 +20,17 @@ Cu.import("resource://gre/modules/Servic
 XPCOMUtils.defineLazyModuleGetter(this, "Promise",
                                   "resource://gre/modules/Promise.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "Task",
                                   "resource://gre/modules/Task.jsm");
 
 /**
  * Handles the requestAutocomplete user interface.
  */
-this.RequestAutocompleteUI = function (aAutofillData) {
+this.RequestAutocompleteUI = function(aAutofillData) {
   this._autofillData = aAutofillData;
 }
 
 this.RequestAutocompleteUI.prototype = {
   _autofillData: null,
 
   show: Task.async(function* () {
     // Create a new promise and store the function that will resolve it.  This
--- a/toolkit/components/formautofill/content/requestAutocomplete.js
+++ b/toolkit/components/formautofill/content/requestAutocomplete.js
@@ -17,30 +17,30 @@ XPCOMUtils.defineLazyModuleGetter(this, 
                                   "resource://gre/modules/Promise.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "Task",
                                   "resource://gre/modules/Task.jsm");
 
 const RequestAutocompleteDialog = {
   resolveFn: null,
   autofillData: null,
 
-  onLoad: function () {
+  onLoad: function() {
     Task.spawn(function* () {
       let args = window.arguments[0].wrappedJSObject;
       this.resolveFn = args.resolveFn;
       this.autofillData = args.autofillData;
 
       window.sizeToContent();
 
       Services.obs.notifyObservers(window,
                                    "formautofill-window-initialized", "");
     }.bind(this)).catch(Cu.reportError);
   },
 
-  onAccept: function () {
+  onAccept: function() {
     // TODO: Replace with autofill storage module (bug 1018304).
     const dummyDB = {
       "": {
         "name": "Mozzy La",
         "street-address": "331 E Evelyn Ave",
         "address-level2": "Mountain View",
         "address-level1": "CA",
         "country": "US",
@@ -73,13 +73,13 @@ const RequestAutocompleteDialog = {
         }
       }
     }
 
     window.close();
     this.resolveFn(result);
   },
 
-  onCancel: function () {
+  onCancel: function() {
     window.close();
     this.resolveFn({ canceled: true });
   },
 };
--- a/toolkit/components/formautofill/test/browser/loader.js
+++ b/toolkit/components/formautofill/test/browser/loader.js
@@ -23,16 +23,16 @@ var Output = {
 // Define assertion functions so they look the same across all frameworks.
 var Assert = {
   ok: _mochitestAssert.ok,
   equal: _mochitestAssert.equal,
 };
 
 // Define task registration functions, see description in "loader_common.js".
 var add_task_in_parent_process = add_task;
-var add_task_in_child_process = function () {};
+var add_task_in_child_process = function() {};
 var add_task_in_both_processes = add_task;
 
 Services.scriptloader.loadSubScript(getRootDirectory(gTestPath) +
                                     "head_common.js", this);
 
 // Reminder: unless you are adding new features to the framework, you shouldn't
 // have to modify this file.  Use "head_common.js" or "head.js" for shared code.
--- a/toolkit/components/formautofill/test/chrome/loader.js
+++ b/toolkit/components/formautofill/test/chrome/loader.js
@@ -25,17 +25,17 @@ Services.scriptloader.loadSubScript(shar
 
 var parentScript = SpecialPowers.loadChromeScript(
                                  SimpleTest.getTestFileURL("loader_parent.js"));
 
 // Replace the extension of the loaded HTML file with ".js"
 var testUrl = location.href.replace(/\.\w+$/, ".js");
 
 // Start loading the test script in the parent process.
-var promiseParentInitFinished = new Promise(function (resolve) {
+var promiseParentInitFinished = new Promise(function(resolve) {
   parentScript.addMessageListener("finish_load_in_parent", resolve);
 });
 parentScript.sendAsyncMessage("start_load_in_parent", { testUrl: testUrl });
 
 // Define output functions so they look the same across all frameworks.
 var Output = {
   print: info,
 };
@@ -73,17 +73,17 @@ window.addEventListener("load", function
       for (let [taskFn, taskType, taskId] of gTestTasks) {
         if (taskType == "content") {
           // This is a normal task executed in the current process.
           info("Running " + taskFn.name);
           yield Task.spawn(taskFn);
         } else {
           // This is a task executed in the parent process.
           info("Running task in parent process: " + taskFn.name);
-          let promiseFinished = new Promise(function (resolve) {
+          let promiseFinished = new Promise(function(resolve) {
             parentScript.addMessageListener("finish_task_" + taskId, resolve);
           });
           parentScript.sendAsyncMessage("start_task_" + taskId);
           yield promiseFinished;
           info("Finished task in parent process: " + taskFn.name);
         }
       }
     } catch (ex) {
--- a/toolkit/components/formautofill/test/chrome/loader_parent.js
+++ b/toolkit/components/formautofill/test/chrome/loader_parent.js
@@ -33,37 +33,37 @@ var Assert = {
   ok: assert.ok,
   equal: assert.equal,
 };
 
 // Define task registration functions, see description in "loader_common.js".
 function add_task_in_parent_process(taskFn, taskIdOverride) {
   let taskId = taskIdOverride || getTaskId(Components.stack.caller);
   Output.print("Registering in the parent process: " + taskId);
-  addMessageListener("start_task_" + taskId, function () {
+  addMessageListener("start_task_" + taskId, function() {
     Task.spawn(function* () {
       try {
         Output.print("Running in the parent process " + taskId);
         yield Task.spawn(taskFn);
       } catch (ex) {
         assert.ok(false, ex);
       }
 
       sendAsyncMessage("finish_task_" + taskId, {});
     });
   });
 }
-var add_task = function () {};
-var add_task_in_child_process = function () {};
+var add_task = function() {};
+var add_task_in_child_process = function() {};
 var add_task_in_both_processes = add_task_in_parent_process;
 
 // We need to wait for the child process to send us the path of the test file
 // to load before we can actually start loading it.
 var context = this;
-addMessageListener("start_load_in_parent", function (message) {
+addMessageListener("start_load_in_parent", function(message) {
   Output.print("Starting loading infrastructure in parent process.");
   let headUrl = "chrome://mochitests/content/chrome/" +
                 "toolkit/components/formautofill/test/chrome/head_common.js";
   Services.scriptloader.loadSubScript(headUrl, context);
 
   Services.scriptloader.loadSubScript(message.testUrl, context);
 
   // Register the execution of termination tasks after all other tasks.
--- a/toolkit/components/formautofill/test/head_common.js
+++ b/toolkit/components/formautofill/test/head_common.js
@@ -37,47 +37,47 @@ var TestUtils = {
    * Waits for at least one tick of the event loop.  This means that all pending
    * events at the time of this call will have been processed.  Other events may
    * be processed before the returned promise is resolved.
    *
    * @return {Promise}
    * @resolves When pending events have been processed.
    * @rejects Never.
    */
-  waitForTick: function () {
+  waitForTick: function() {
     return new Promise(resolve => executeSoon(resolve));
   },
 
   /**
    * Waits for the specified timeout.
    *
    * @param aTimeMs
    *        Minimum time to wait from the moment of this call, in milliseconds.
    *        The actual wait may be longer, due to system timer resolution and
    *        pending events being processed before the promise is resolved.
    *
    * @return {Promise}
    * @resolves When the specified time has passed.
    * @rejects Never.
    */
-  waitMs: function (aTimeMs) {
+  waitMs: function(aTimeMs) {
     return new Promise(resolve => setTimeout(resolve, aTimeMs));
   },
 
   /**
    * Allows waiting for an observer notification once.
    *
    * @param aTopic
    *        Notification topic to observe.
    *
    * @return {Promise}
    * @resolves The array [aSubject, aData] from the observed notification.
    * @rejects Never.
    */
-  waitForNotification: function (aTopic) {
+  waitForNotification: function(aTopic) {
     Output.print("Waiting for notification: '" + aTopic + "'.");
 
     return new Promise(resolve => Services.obs.addObserver(
       function observe(aSubject, aTopic, aData) {
         Services.obs.removeObserver(observe, aTopic);
         resolve([aSubject, aData]);
       }, aTopic, false));
   },
@@ -91,17 +91,17 @@ var TestUtils = {
    *        String with the name of the event.
    * @param aUseCapture
    *        This parameter is passed to the addEventListener call.
    *
    * @return {Promise}
    * @resolves The arguments from the observed event.
    * @rejects Never.
    */
-  waitForEvent: function (aTarget, aEventName, aUseCapture = false) {
+  waitForEvent: function(aTarget, aEventName, aUseCapture = false) {
     Output.print("Waiting for event: '" + aEventName + "' on " + aTarget + ".");
 
     return new Promise(resolve => aTarget.addEventListener(aEventName,
       function onEvent(...aArgs) {
         aTarget.removeEventListener(aEventName, onEvent, aUseCapture);
         resolve(...aArgs);
       }, aUseCapture));
   },
--- a/toolkit/components/formautofill/test/loader_common.js
+++ b/toolkit/components/formautofill/test/loader_common.js
@@ -99,22 +99,22 @@ function add_termination_task(taskFn) {
  * between the parent and child processes.
  */
 function getTaskId(stackFrame) {
   return stackFrame.filename + ":" + stackFrame.lineNumber;
 }
 
 // This is a shared helper for mochitest-chrome and mochitest-browser.
 var _mochitestAssert = {
-  ok: function (actual) {
+  ok: function(actual) {
     let stack = Components.stack.caller;
     ok(actual, "[" + stack.name + " : " + stack.lineNumber + "] " + actual +
                " == true");
   },
-  equal: function (actual, expected) {
+  equal: function(actual, expected) {
     let stack = Components.stack.caller;
     is(actual, expected, "[" + stack.name + " : " + stack.lineNumber + "] " +
                actual + " == " + expected);
   },
 };
 
 // Reminder: unless you are adding new features to the framework, you shouldn't
 // have to modify this file.  Use "head_common.js" or "head.js" for shared code.
--- a/toolkit/components/formautofill/test/xpcshell/loader.js
+++ b/toolkit/components/formautofill/test/xpcshell/loader.js
@@ -25,17 +25,17 @@ var Output = {
   print: do_print,
 };
 
 var executeSoon = do_execute_soon;
 var setTimeout = (fn, delay) => do_timeout(delay, fn);
 
 // Define task registration functions, see description in "loader_common.js".
 var add_task_in_parent_process = add_task;
-var add_task_in_child_process = function () {};
+var add_task_in_child_process = function() {};
 var add_task_in_both_processes = add_task;
 
 Services.scriptloader.loadSubScript(
   Services.io.newFileURI(do_get_file("head_common.js")).spec, this);
 
 // Tests are always run asynchronously and with the profile loaded.
 function run_test() {
   do_get_profile();
--- a/toolkit/components/gfx/content/gfxFrameScript.js
+++ b/toolkit/components/gfx/content/gfxFrameScript.js
@@ -30,17 +30,17 @@ const gfxFrameScript = {
   isSanityTest: function(aUri) {
     if (!aUri) {
       return false;
     }
 
     return aUri.endsWith("/sanitytest.html");
   },
 
-  onStateChange: function (webProgress, req, flags, status) {
+  onStateChange: function(webProgress, req, flags, status) {
     if (webProgress.isTopLevel &&
         (flags & Ci.nsIWebProgressListener.STATE_STOP) &&
         this.isSanityTest(req.name)) {
 
       webProgress.removeProgressListener(this);
 
       // If no paint is pending, then the test already painted
       if (this.domUtils.isMozAfterPaintPending) {
--- a/toolkit/components/jsdownloads/src/DownloadCore.jsm
+++ b/toolkit/components/jsdownloads/src/DownloadCore.jsm
@@ -143,17 +143,17 @@ const kProgressUpdateIntervalMs = 400;
 
 // Download
 
 /**
  * Represents a single download, with associated state and actions.  This object
  * is transient, though it can be included in a DownloadList so that it can be
  * managed by the user interface and persisted across sessions.
  */
-this.Download = function ()
+this.Download = function()
 {
   this._deferSucceeded = Promise.defer();
 }
 
 this.Download.prototype = {
   /**
    * DownloadSource object associated with this download.
    */
@@ -705,17 +705,17 @@ this.Download.prototype = {
    * @return {Promise}
    * @resolves When the instruction to launch the file has been
    *           successfully given to the operating system. Note that
    *           the OS might still take a while until the file is actually
    *           launched.
    * @rejects  JavaScript exception if there was an error trying to launch
    *           the file.
    */
-  launch: function () {
+  launch: function() {
     if (!this.succeeded) {
       return Promise.reject(
         new Error("launch can only be called if the download succeeded")
       );
     }
 
     return DownloadIntegration.launchDownload(this);
   },
@@ -839,17 +839,17 @@ this.Download.prototype = {
    * After this method has been called, if the tryToKeepPartialData property is
    * still true when the download is restarted, partial data will be retained
    * during the new download attempt.
    *
    * @return {Promise}
    * @resolves When the partial data has been successfully removed.
    * @rejects JavaScript exception if the operation could not be completed.
    */
-  removePartialData: function ()
+  removePartialData: function()
   {
     if (!this.canceled && !this.error) {
       return Promise.resolve();
     }
 
     let promiseRemovePartialData = this._promiseRemovePartialData;
 
     if (!promiseRemovePartialData) {
@@ -914,17 +914,17 @@ this.Download.prototype = {
    *
    * This allows the properties of the download to be updated in case the user
    * moved or deleted the target file or its associated ".part" file.
    *
    * @return {Promise}
    * @resolves When the operation has completed.
    * @rejects Never.
    */
-  refresh: function ()
+  refresh: function()
   {
     return Task.spawn(function* () {
       if (!this.stopped || this._finalized) {
         return;
       }
 
       if (this.succeeded) {
         let oldExists = this.target.exists;
@@ -993,17 +993,17 @@ this.Download.prototype = {
    *        Whether any partially downloaded data should be removed after the
    *        download has been stopped.
    *
    * @return {Promise}
    * @resolves When the operation has finished successfully.
    * @rejects JavaScript exception if an error occurred while removing the
    *          partially downloaded data.
    */
-  finalize: function (aRemovePartialData)
+  finalize: function(aRemovePartialData)
   {
     // Prevents the download from starting again after having been stopped.
     this._finalized = true;
 
     if (aRemovePartialData) {
       // Cancel the download, in case it is currently in progress, then remove
       // any partially downloaded data.  The removal operation waits for
       // cancellation to be completed before resolving the promise it returns.
@@ -1090,17 +1090,17 @@ this.Download.prototype = {
     }
   },
 
   /**
    * Returns a static representation of the current object state.
    *
    * @return A JavaScript object that can be serialized to JSON.
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     let serializable = {
       source: this.source.toSerializable(),
       target: this.target.toSerializable(),
     };
 
     let saver = this.saver.toSerializable();
     if (!serializable.source || !saver) {
@@ -1142,17 +1142,17 @@ this.Download.prototype = {
    * object that should be saved into a file also change.  This excludes
    * properties whose value doesn't usually change during the download lifetime.
    *
    * This function is used to determine whether the download should be
    * serialized after a property change notification has been received.
    *
    * @return String representing the relevant download state.
    */
-  getSerializationHash: function ()
+  getSerializationHash: function()
   {
     // The "succeeded", "canceled", "error", and startTime properties are not
     // taken into account because they all change before the "stopped" property
     // changes, and are not altered in other cases.
     return this.stopped + "," + this.totalBytes + "," + this.hasPartialData +
            "," + this.contentType;
   },
 };
@@ -1187,17 +1187,17 @@ const kPlainSerializableDownloadProperti
  *                  See DownloadTarget.fromSerializable for details.
  *          saver: Serializable representation of a DownloadSaver object.  See
  *                 DownloadSaver.fromSerializable for details.  If omitted,
  *                 defaults to "copy".
  *        }
  *
  * @return The newly created Download object.
  */
-Download.fromSerializable = function (aSerializable) {
+Download.fromSerializable = function(aSerializable) {
   let download = new Download();
   if (aSerializable.source instanceof DownloadSource) {
     download.source = aSerializable.source;
   } else {
     download.source = DownloadSource.fromSerializable(aSerializable.source);
   }
   if (aSerializable.target instanceof DownloadTarget) {
     download.target = aSerializable.target;
@@ -1247,17 +1247,17 @@ Download.fromSerializable = function (aS
   return download;
 };
 
 // DownloadSource
 
 /**
  * Represents the source of a download, for example a document or an URI.
  */
-this.DownloadSource = function () {}
+this.DownloadSource = function() {}
 
 this.DownloadSource.prototype = {
   /**
    * String containing the URI for the download source.
    */
   url: null,
 
   /**
@@ -1290,17 +1290,17 @@ this.DownloadSource.prototype = {
    */
    adjustChannel: null,
 
   /**
    * Returns a static representation of the current object state.
    *
    * @return A JavaScript object that can be serialized to JSON.
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     if (this.adjustChannel) {
       // If the callback was used, we can't reproduce this across sessions.
       return null;
     }
 
     // Simplify the representation if we don't have other details.
     if (!this.isPrivate && !this.referrer && !this._unknownProperties) {
@@ -1337,17 +1337,17 @@ this.DownloadSource.prototype = {
  *          adjustChannel: For downloads handled by (default) DownloadCopySaver,
  *                         this function can adjust the network channel before
  *                         it is opened, for example to change the HTTP headers
  *                         or to upload a stream as POST data.  Optional.
  *        }
  *
  * @return The newly created DownloadSource object.
  */
-this.DownloadSource.fromSerializable = function (aSerializable) {
+this.DownloadSource.fromSerializable = function(aSerializable) {
   let source = new DownloadSource();
   if (isString(aSerializable)) {
     // Convert String objects to primitive strings at this point.
     source.url = aSerializable.toString();
   } else if (aSerializable instanceof Ci.nsIURI) {
     source.url = aSerializable.spec;
   } else if (aSerializable instanceof Ci.nsIDOMWindow) {
     source.url = aSerializable.location.href;
@@ -1374,17 +1374,17 @@ this.DownloadSource.fromSerializable = f
 };
 
 // DownloadTarget
 
 /**
  * Represents the target of a download, for example a file in the global
  * downloads directory, or a file in the system temporary directory.
  */
-this.DownloadTarget = function () {}
+this.DownloadTarget = function() {}
 
 this.DownloadTarget.prototype = {
   /**
    * String containing the path of the target file.
    */
   path: null,
 
   /**
@@ -1446,17 +1446,17 @@ this.DownloadTarget.prototype = {
     }
   }),
 
   /**
    * Returns a static representation of the current object state.
    *
    * @return A JavaScript object that can be serialized to JSON.
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     // Simplify the representation if we don't have other details.
     if (!this.partFilePath && !this._unknownProperties) {
       return this.path;
     }
 
     let serializable = { path: this.path,
                          partFilePath: this.partFilePath };
@@ -1474,17 +1474,17 @@ this.DownloadTarget.prototype = {
  *        object with the following properties:
  *        {
  *          path: String containing the path of the target file.
  *          partFilePath: optional string containing the part file path.
  *        }
  *
  * @return The newly created DownloadTarget object.
  */
-this.DownloadTarget.fromSerializable = function (aSerializable) {
+this.DownloadTarget.fromSerializable = function(aSerializable) {
   let target = new DownloadTarget();
   if (isString(aSerializable)) {
     // Convert String objects to primitive strings at this point.
     target.path = aSerializable.toString();
   } else if (aSerializable instanceof Ci.nsIFile) {
     // Read the "path" property of nsIFile after checking the object type.
     target.path = aSerializable.path;
   } else {
@@ -1516,17 +1516,17 @@ this.DownloadTarget.fromSerializable = f
  *                        download is a network failure or a local file failure,
  *                        based on a set of known values of the result code.
  *                        This is useful when the error is received by a
  *                        component that handles both aspects of the download.
  *          }
  *        The properties object may also contain any of the DownloadError's
  *        because properties, which will be set accordingly in the error object.
  */
-this.DownloadError = function (aProperties)
+this.DownloadError = function(aProperties)
 {
   const NS_ERROR_MODULE_BASE_OFFSET = 0x45;
   const NS_ERROR_MODULE_NETWORK = 6;
   const NS_ERROR_MODULE_FILES = 13;
 
   // Set the error name used by the Error object prototype first.
   this.name = "DownloadError";
   this.result = aProperties.result || Cr.NS_ERROR_FAILURE;
@@ -1648,17 +1648,17 @@ this.DownloadError.prototype = {
    */
   innerException: null,
 
   /**
    * Returns a static representation of the current object state.
    *
    * @return A JavaScript object that can be serialized to JSON.
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     let serializable = {
       result: this.result,
       message: this.message,
       becauseSourceFailed: this.becauseSourceFailed,
       becauseTargetFailed: this.becauseTargetFailed,
       becauseBlocked: this.becauseBlocked,
       becauseBlockedByParentalControls: this.becauseBlockedByParentalControls,
@@ -1675,17 +1675,17 @@ this.DownloadError.prototype = {
 /**
  * Creates a new DownloadError object from its serializable representation.
  *
  * @param aSerializable
  *        Serializable representation of a DownloadError object.
  *
  * @return The newly created DownloadError object.
  */
-this.DownloadError.fromSerializable = function (aSerializable) {
+this.DownloadError.fromSerializable = function(aSerializable) {
   let e = new DownloadError(aSerializable);
   deserializeUnknownProperties(e, aSerializable, property =>
     property != "result" &&
     property != "message" &&
     property != "becauseSourceFailed" &&
     property != "becauseTargetFailed" &&
     property != "becauseBlocked" &&
     property != "becauseBlockedByParentalControls" &&
@@ -1696,17 +1696,17 @@ this.DownloadError.fromSerializable = fu
   return e;
 };
 
 // DownloadSaver
 
 /**
  * Template for an object that actually transfers the data for the download.
  */
-this.DownloadSaver = function () {}
+this.DownloadSaver = function() {}
 
 this.DownloadSaver.prototype = {
   /**
    * Download object for raising notifications and reading properties.
    *
    * If the tryToKeepPartialData property of the download object is false, the
    * saver should never try to keep partially downloaded data if the download
    * fails.
@@ -1763,17 +1763,17 @@ this.DownloadSaver.prototype = {
     return Promise.resolve();
   },
 
   /**
    * This can be called by the saver implementation when the download is already
    * started, to add it to the browsing history.  This method has no effect if
    * the download is private.
    */
-  addToHistory: function ()
+  addToHistory: function()
   {
     if (this.download.source.isPrivate) {
       return;
     }
 
     let sourceUri = NetUtil.newURI(this.download.source.url);
     let referrer = this.download.source.referrer;
     let referrerUri = referrer ? NetUtil.newURI(referrer) : null;
@@ -1800,46 +1800,46 @@ this.DownloadSaver.prototype = {
     }
   },
 
   /**
    * Returns a static representation of the current object state.
    *
    * @return A JavaScript object that can be serialized to JSON.
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     throw new Error("Not implemented.");
   },
 
   /**
    * Returns the SHA-256 hash of the downloaded file, if it exists.
    */
-  getSha256Hash: function ()
+  getSha256Hash: function()
   {
     throw new Error("Not implemented.");
   },
 
-  getSignatureInfo: function ()
+  getSignatureInfo: function()
   {
     throw new Error("Not implemented.");
   },
 }; // DownloadSaver
 
 /**
  * Creates a new DownloadSaver object from its serializable representation.
  *
  * @param aSerializable
  *        Serializable representation of a DownloadSaver object.  If no initial
  *        state information for the saver object is needed, can be a string
  *        representing the class of the download operation, for example "copy".
  *
  * @return The newly created DownloadSaver object.
  */
-this.DownloadSaver.fromSerializable = function (aSerializable) {
+this.DownloadSaver.fromSerializable = function(aSerializable) {
   let serializable = isString(aSerializable) ? { type: aSerializable }
                                              : aSerializable;
   let saver;
   switch (serializable.type) {
     case "copy":
       saver = DownloadCopySaver.fromSerializable(serializable);
       break;
     case "legacy":
@@ -1854,17 +1854,17 @@ this.DownloadSaver.fromSerializable = fu
   return saver;
 };
 
 // DownloadCopySaver
 
 /**
  * Saver object that simply copies the entire source file to the target.
  */
-this.DownloadCopySaver = function () {}
+this.DownloadCopySaver = function() {}
 
 this.DownloadCopySaver.prototype = {
   __proto__: DownloadSaver.prototype,
 
   /**
    * BackgroundFileSaver object currently handling the download.
    */
   _backgroundFileSaver: null,
@@ -1962,17 +1962,17 @@ this.DownloadCopySaver.prototype = {
         }
 
         // Create the object that will save the file in a background thread.
         let backgroundFileSaver = new BackgroundFileSaverStreamListener();
         try {
           // When the operation completes, reflect the status in the promise
           // returned by this download execution function.
           backgroundFileSaver.observer = {
-            onTargetChange: function () { },
+            onTargetChange: function() { },
             onSaveComplete: (aSaver, aStatus) => {
               // Send notifications now that we can restart if needed.
               if (Components.isSuccessCode(aStatus)) {
                 // Save the hash before freeing backgroundFileSaver.
                 this._sha256Hash = aSaver.sha256Hash;
                 this._signatureInfo = aSaver.signatureInfo;
                 this._redirects = aSaver.redirects;
                 deferSaveComplete.resolve();
@@ -2027,28 +2027,28 @@ this.DownloadCopySaver.prototype = {
                                                  aProgressMax)
             {
               let currentBytes = resumeFromBytes + aProgress;
               let totalBytes = aProgressMax == -1 ? -1 : (resumeFromBytes +
                                                           aProgressMax);
               aSetProgressBytesFn(currentBytes, totalBytes, aProgress > 0 &&
                                   partFilePath && keepPartialData);
             },
-            onStatus: function () { },
+            onStatus: function() { },
           };
 
           // If the callback was set, handle it now before opening the channel.
           if (download.source.adjustChannel) {
             yield download.source.adjustChannel(channel);
           }
 
           // Open the channel, directing output to the background file saver.
           backgroundFileSaver.QueryInterface(Ci.nsIStreamListener);
           channel.asyncOpen2({
-            onStartRequest: function (aRequest, aContext) {
+            onStartRequest: function(aRequest, aContext) {
               backgroundFileSaver.onStartRequest(aRequest, aContext);
 
               // Check if the request's response has been blocked by Windows
               // Parental Controls with an HTTP 450 error code.
               if (aRequest instanceof Ci.nsIHttpChannel &&
                   aRequest.responseStatus == 450) {
                 // Set a flag that can be retrieved later when handling the
                 // cancellation so that the proper error can be thrown.
@@ -2119,32 +2119,32 @@ this.DownloadCopySaver.prototype = {
                                               keepPartialData);
               } else {
                 // Set the final target file, and delete it on failure.
                 backgroundFileSaver.setTarget(new FileUtils.File(targetPath),
                                               false);
               }
             }.bind(copySaver),
 
-            onStopRequest: function (aRequest, aContext, aStatusCode) {
+            onStopRequest: function(aRequest, aContext, aStatusCode) {
               try {
                 backgroundFileSaver.onStopRequest(aRequest, aContext,
                                                   aStatusCode);
               } finally {
                 // If the data transfer completed successfully, indicate to the
                 // background file saver that the operation can finish.  If the
                 // data transfer failed, the saver has been already stopped.
                 if (Components.isSuccessCode(aStatusCode)) {
                   backgroundFileSaver.finish(Cr.NS_OK);
                 }
               }
             }.bind(copySaver),
 
-            onDataAvailable: function (aRequest, aContext, aInputStream,
-                                       aOffset, aCount) {
+            onDataAvailable: function(aRequest, aContext, aInputStream,
+                                      aOffset, aCount) {
               backgroundFileSaver.onDataAvailable(aRequest, aContext,
                                                   aInputStream, aOffset,
                                                   aCount);
             }.bind(copySaver),
           });
 
           // We should check if we have been canceled in the meantime, after
           // all the previous asynchronous operations have been executed and
@@ -2251,17 +2251,17 @@ this.DownloadCopySaver.prototype = {
       this._backgroundFileSaver.finish(Cr.NS_ERROR_FAILURE);
       this._backgroundFileSaver = null;
     }
   },
 
   /**
    * Implements "DownloadSaver.removePartialData".
    */
-  removePartialData: function ()
+  removePartialData: function()
   {
     return Task.spawn(function* task_DCS_removePartialData() {
       if (this.download.target.partFilePath) {
         try {
           yield OS.File.remove(this.download.target.partFilePath);
         } catch (ex) {
           if (!(ex instanceof OS.File.Error) || !ex.becauseNoSuchFile) {
             throw ex;
@@ -2269,64 +2269,64 @@ this.DownloadCopySaver.prototype = {
         }
       }
     }.bind(this));
   },
 
   /**
    * Implements "DownloadSaver.toSerializable".
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     // Simplify the representation if we don't have other details.
     if (!this.entityID && !this._unknownProperties) {
       return "copy";
     }
 
     let serializable = { type: "copy",
                          entityID: this.entityID };
     serializeUnknownProperties(this, serializable);
     return serializable;
   },
 
   /**
    * Implements "DownloadSaver.getSha256Hash"
    */
-  getSha256Hash: function ()
+  getSha256Hash: function()
   {
     return this._sha256Hash;
   },
 
   /*
    * Implements DownloadSaver.getSignatureInfo.
    */
-  getSignatureInfo: function ()
+  getSignatureInfo: function()
   {
     return this._signatureInfo;
   },
 
   /*
    * Implements DownloadSaver.getRedirects.
    */
-  getRedirects: function ()
+  getRedirects: function()
   {
     return this._redirects;
   }
 };
 
 /**
  * Creates a new DownloadCopySaver object, with its initial state derived from
  * its serializable representation.
  *
  * @param aSerializable
  *        Serializable representation of a DownloadCopySaver object.
  *
  * @return The newly created DownloadCopySaver object.
  */
-this.DownloadCopySaver.fromSerializable = function (aSerializable) {
+this.DownloadCopySaver.fromSerializable = function(aSerializable) {
   let saver = new DownloadCopySaver();
   if ("entityID" in aSerializable) {
     saver.entityID = aSerializable.entityID;
   }
 
   deserializeUnknownProperties(saver, aSerializable, property =>
     property != "entityID" && property != "type");
 
@@ -2335,17 +2335,17 @@ this.DownloadCopySaver.fromSerializable 
 
 // DownloadLegacySaver
 
 /**
  * Saver object that integrates with the legacy nsITransfer interface.
  *
  * For more background on the process, see the DownloadLegacyTransfer object.
  */
-this.DownloadLegacySaver = function ()
+this.DownloadLegacySaver = function()
 {
   this.deferExecuted = Promise.defer();
   this.deferCanceled = Promise.defer();
 }
 
 this.DownloadLegacySaver.prototype = {
   __proto__: DownloadSaver.prototype,
 
@@ -2434,17 +2434,17 @@ this.DownloadLegacySaver.prototype = {
    *        nsIRequest associated to the status update.
    * @param aAlreadyAddedToHistory
    *        Indicates that the nsIExternalHelperAppService component already
    *        added the download to the browsing history, unless it was started
    *        from a private browsing window.  When this parameter is false, the
    *        download is added to the browsing history here.  Private downloads
    *        are never added to history even if this parameter is false.
    */
-  onTransferStarted: function (aRequest, aAlreadyAddedToHistory)
+  onTransferStarted: function(aRequest, aAlreadyAddedToHistory)
   {
     // Store the entity ID to use for resuming if required.
     if (this.download.tryToKeepPartialData &&
         aRequest instanceof Ci.nsIResumableChannel) {
       try {
         // If reading the ID succeeds, the source is resumable.
         this.entityID = aRequest.entityID;
       } catch (ex) {
@@ -2597,17 +2597,17 @@ this.DownloadLegacySaver.prototype = {
         this.request = null;
         this.deferCanceled = null;
         // Allow the download to restart through a DownloadCopySaver.
         this.firstExecutionFinished = true;
       }
     }.bind(this));
   },
 
-  _checkReputationAndMove: function () {
+  _checkReputationAndMove: function() {
     return DownloadCopySaver.prototype._checkReputationAndMove
                                       .apply(this, arguments);
   },
 
   /**
    * Implements "DownloadSaver.cancel".
    */
   cancel: function DLS_cancel()
@@ -2623,134 +2623,134 @@ this.DownloadLegacySaver.prototype = {
     if (this.deferCanceled) {
       this.deferCanceled.resolve();
     }
   },
 
   /**
    * Implements "DownloadSaver.removePartialData".
    */
-  removePartialData: function ()
+  removePartialData: function()
   {
     // DownloadCopySaver and DownloadLeagcySaver use the same logic for removing
     // partially downloaded data, though this implementation isn't shared by
     // other saver types, thus it isn't found on their shared prototype.
     return DownloadCopySaver.prototype.removePartialData.call(this);
   },
 
   /**
    * Implements "DownloadSaver.toSerializable".
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     // This object depends on legacy components that are created externally,
     // thus it cannot be rebuilt during deserialization.  To support resuming
     // across different browser sessions, this object is transformed into a
     // DownloadCopySaver for the purpose of serialization.
     return DownloadCopySaver.prototype.toSerializable.call(this);
   },
 
   /**
    * Implements "DownloadSaver.getSha256Hash".
    */
-  getSha256Hash: function ()
+  getSha256Hash: function()
   {
     if (this.copySaver) {
       return this.copySaver.getSha256Hash();
     }
     return this._sha256Hash;
   },
 
   /**
    * Called by the nsITransfer implementation when the hash is available.
    */
-  setSha256Hash: function (hash)
+  setSha256Hash: function(hash)
   {
     this._sha256Hash = hash;
   },
 
   /**
    * Implements "DownloadSaver.getSignatureInfo".
    */
-  getSignatureInfo: function ()
+  getSignatureInfo: function()
   {
     if (this.copySaver) {
       return this.copySaver.getSignatureInfo();
     }
     return this._signatureInfo;
   },
 
   /**
    * Called by the nsITransfer implementation when the hash is available.
    */
-  setSignatureInfo: function (signatureInfo)
+  setSignatureInfo: function(signatureInfo)
   {
     this._signatureInfo = signatureInfo;
   },
 
   /**
    * Implements "DownloadSaver.getRedirects".
    */
-  getRedirects: function ()
+  getRedirects: function()
   {
     if (this.copySaver) {
       return this.copySaver.getRedirects();
     }
     return this._redirects;
   },
 
   /**
    * Called by the nsITransfer implementation when the redirect chain is
    * available.
    */
-  setRedirects: function (redirects)
+  setRedirects: function(redirects)
   {
     this._redirects = redirects;
   },
 };
 
 /**
  * Returns a new DownloadLegacySaver object.  This saver type has a
  * deserializable form only when creating a new object in memory, because it
  * cannot be serialized to disk.
  */
-this.DownloadLegacySaver.fromSerializable = function () {
+this.DownloadLegacySaver.fromSerializable = function() {
   return new DownloadLegacySaver();
 };
 
 // DownloadPDFSaver
 
 /**
  * This DownloadSaver type creates a PDF file from the current document in a
  * given window, specified using the windowRef property of the DownloadSource
  * object associated with the download.
  *
  * In order to prevent the download from saving a different document than the one
  * originally loaded in the window, any attempt to restart the download will fail.
  *
  * Since this DownloadSaver type requires a live document as a source, it cannot
  * be persisted across sessions, unless the download already succeeded.
  */
-this.DownloadPDFSaver = function () {
+this.DownloadPDFSaver = function() {
 }
 
 this.DownloadPDFSaver.prototype = {
   __proto__: DownloadSaver.prototype,
 
   /**
    * An nsIWebBrowserPrint instance for printing this page.
    * This is null when saving has not started or has completed,
    * or while the operation is being canceled.
    */
   _webBrowserPrint: null,
 
   /**
    * Implements "DownloadSaver.execute".
    */
-  execute: function (aSetProgressBytesFn, aSetPropertiesFn)
+  execute: function(aSetProgressBytesFn, aSetPropertiesFn)
   {
     return Task.spawn(function* task_DCS_execute() {
       if (!this.download.source.windowRef) {
         throw new DownloadError({
           message: "PDF saver must be passed an open window, and cannot be restarted.",
           becauseSourceFailed: true,
         });
       }
@@ -2795,34 +2795,34 @@ this.DownloadPDFSaver.prototype = {
       printSettings.footerStrRight = "";
 
       this._webBrowserPrint = win.QueryInterface(Ci.nsIInterfaceRequestor)
                                  .getInterface(Ci.nsIWebBrowserPrint);
 
       try {
         yield new Promise((resolve, reject) => {
           this._webBrowserPrint.print(printSettings, {
-            onStateChange: function (webProgress, request, stateFlags, status) {
+            onStateChange: function(webProgress, request, stateFlags, status) {
               if (stateFlags & Ci.nsIWebProgressListener.STATE_STOP) {
                 if (!Components.isSuccessCode(status)) {
                   reject(new DownloadError({ result: status,
                                              inferCause: true }));
                 } else {
                   resolve();
                 }
               }
             },
-            onProgressChange: function (webProgress, request, curSelfProgress,
-                                        maxSelfProgress, curTotalProgress,
-                                        maxTotalProgress) {
+            onProgressChange: function(webProgress, request, curSelfProgress,
+                                       maxSelfProgress, curTotalProgress,
+                                       maxTotalProgress) {
               aSetProgressBytesFn(curTotalProgress, maxTotalProgress, false);
             },
-            onLocationChange: function () {},
-            onStatusChange: function () {},
-            onSecurityChange: function () {},
+            onLocationChange: function() {},
+            onStatusChange: function() {},
+            onSecurityChange: function() {},
           });
         });
       } finally {
         // Remove the print object to avoid leaks
         this._webBrowserPrint = null;
       }
 
       let fileInfo = yield OS.File.stat(targetPath);
@@ -2839,17 +2839,17 @@ this.DownloadPDFSaver.prototype = {
       this._webBrowserPrint.cancel();
       this._webBrowserPrint = null;
     }
   },
 
   /**
    * Implements "DownloadSaver.toSerializable".
    */
-  toSerializable: function ()
+  toSerializable: function()
   {
     if (this.download.succeeded) {
       return DownloadCopySaver.prototype.toSerializable.call(this);
     }
 
     // This object needs a window to recreate itself. If it didn't succeded
     // it will not be possible to restart. Returning null here will
     // prevent us from serializing it at all.
@@ -2861,11 +2861,11 @@ this.DownloadPDFSaver.prototype = {
  * Creates a new DownloadPDFSaver object, with its initial state derived from
  * its serializable representation.
  *
  * @param aSerializable
  *        Serializable representation of a DownloadPDFSaver object.
  *
  * @return The newly created DownloadPDFSaver object.
  */
-this.DownloadPDFSaver.fromSerializable = function (aSerializable) {
+this.DownloadPDFSaver.fromSerializable = function(aSerializable) {
   return new DownloadPDFSaver();
 };
--- a/toolkit/components/jsdownloads/src/DownloadImport.jsm
+++ b/toolkit/components/jsdownloads/src/DownloadImport.jsm
@@ -46,34 +46,34 @@ const DOWNLOAD_QUEUED = 5;
 /**
  * Provides an object that has a method to import downloads
  * from the previous SQLite storage format.
  *
  * @param aList   A DownloadList where each successfully
  *                imported download will be added.
  * @param aPath   The path to the database file.
  */
-this.DownloadImport = function (aList, aPath)
+this.DownloadImport = function(aList, aPath)
 {
   this.list = aList;
   this.path = aPath;
 }
 
 this.DownloadImport.prototype = {
   /**
    * Imports unfinished downloads from the previous SQLite storage
    * format (supporting schemas 7 and up), to the new Download object
    * format. Each imported download will be added to the DownloadList
    *
    * @return {Promise}
    * @resolves When the operation has completed (i.e., every download
    *           from the previous database has been read and added to
    *           the DownloadList)
    */
-  import: function () {
+  import: function() {
     return Task.spawn(function* task_DI_import() {
       let connection = yield Sqlite.openConnection({ path: this.path });
 
       try {
         let schemaVersion = yield connection.getSchemaVersion();
         // We don't support schemas older than version 7 (from 2007)
         // - Version 7 added the columns mimeType, preferredApplication
         //   and preferredAction in 2007
--- a/toolkit/components/jsdownloads/src/DownloadLegacy.js
+++ b/toolkit/components/jsdownloads/src/DownloadLegacy.js
@@ -161,17 +161,17 @@ DownloadLegacyTransfer.prototype = {
                                                   aCurTotalProgress,
                                                   aMaxTotalProgress)
   {
     this.onProgressChange64(aWebProgress, aRequest, aCurSelfProgress,
                             aMaxSelfProgress, aCurTotalProgress,
                             aMaxTotalProgress);
   },
 
-  onLocationChange: function () { },
+  onLocationChange: function() { },
 
   onStatusChange: function DLT_onStatusChange(aWebProgress, aRequest, aStatus,
                                               aMessage)
   {
     // The status change may optionally be received in addition to the state
     // change, but if no network request actually started, it is possible that
     // we only receive a status change with an error status code.
     if (!Components.isSuccessCode(aStatus)) {
@@ -179,17 +179,17 @@ DownloadLegacyTransfer.prototype = {
 
       // Wait for the associated Download object to be available.
       this._deferDownload.promise.then(function DLT_OSC_onDownload(aDownload) {
         aDownload.saver.onTransferFinished(aRequest, aStatus);
       }).then(null, Cu.reportError);
     }
   },
 
-  onSecurityChange: function () { },
+  onSecurityChange: function() { },
 
   // nsIWebProgressListener2
 
   onProgressChange64: function DLT_onProgressChange64(aWebProgress, aRequest,
                                                       aCurSelfProgress,
                                                       aMaxSelfProgress,
                                                       aCurTotalProgress,
                                                       aMaxTotalProgress)
@@ -252,27 +252,27 @@ DownloadLegacyTransfer.prototype = {
       // Start processing all the other events received through nsITransfer.
       this._deferDownload.resolve(aDownload);
 
       // Add the download to the list, allowing it to be seen and canceled.
       return Downloads.getList(Downloads.ALL).then(list => list.add(aDownload));
     }.bind(this)).then(null, Cu.reportError);
   },
 
-  setSha256Hash: function (hash)
+  setSha256Hash: function(hash)
   {
     this._sha256Hash = hash;
   },
 
-  setSignatureInfo: function (signatureInfo)
+  setSignatureInfo: function(signatureInfo)
   {
     this._signatureInfo = signatureInfo;
   },
 
-  setRedirects: function (redirects)
+  setRedirects: function(redirects)
   {
     this._redirects = redirects;
   },
 
   // Private methods and properties
 
   /**
    * This deferred object contains a promise that is resolved with the Download
--- a/toolkit/components/jsdownloads/src/DownloadList.jsm
+++ b/toolkit/components/jsdownloads/src/DownloadList.jsm
@@ -41,17 +41,17 @@ XPCOMUtils.defineLazyModuleGetter(this, 
                                   "resource://gre/modules/Task.jsm");
 
 // DownloadList
 
 /**
  * Represents a collection of Download objects that can be viewed and managed by
  * the user interface, and persisted across sessions.
  */
-this.DownloadList = function ()
+this.DownloadList = function()
 {
   this._downloads = [];
   this._views = new Set();
 }
 
 this.DownloadList.prototype = {
   /**
    * Array of Download objects currently in the list.
@@ -199,17 +199,17 @@ this.DownloadList.prototype = {
   /**
    * Notifies all the views of a download addition, change, or removal.
    *
    * @param aMethodName
    *        String containing the name of the method to call on the view.
    * @param aDownload
    *        The Download object that changed.
    */
-  _notifyAllViews: function (aMethodName, aDownload) {
+  _notifyAllViews: function(aMethodName, aDownload) {
     for (let view of this._views) {
       try {
         if (aMethodName in view) {
           view[aMethodName](aDownload);
         }
       } catch (ex) {
         Cu.reportError(ex);
       }
@@ -262,17 +262,17 @@ this.DownloadList.prototype = {
  * underlying lists, based on their "source.isPrivate" property.  Views on this
  * list will receive notifications for both public and private downloads.
  *
  * @param aPublicList
  *        Underlying DownloadList containing public downloads.
  * @param aPrivateList
  *        Underlying DownloadList containing private downloads.
  */
-this.DownloadCombinedList = function (aPublicList, aPrivateList)
+this.DownloadCombinedList = function(aPublicList, aPrivateList)
 {
   DownloadList.call(this);
   this._publicList = aPublicList;
   this._privateList = aPrivateList;
   aPublicList.addView(this).then(null, Cu.reportError);
   aPrivateList.addView(this).then(null, Cu.reportError);
 }
 
@@ -300,17 +300,17 @@ this.DownloadCombinedList.prototype = {
    *
    * @param aDownload
    *        The Download object to add.
    *
    * @return {Promise}
    * @resolves When the download has been added.
    * @rejects JavaScript exception.
    */
-  add: function (aDownload)
+  add: function(aDownload)
   {
     if (aDownload.source.isPrivate) {
       return this._privateList.add(aDownload);
     }
     return this._publicList.add(aDownload);
   },
 
   /**
@@ -324,53 +324,53 @@ this.DownloadCombinedList.prototype = {
    *
    * @param aDownload
    *        The Download object to remove.
    *
    * @return {Promise}
    * @resolves When the download has been removed.
    * @rejects JavaScript exception.
    */
-  remove: function (aDownload)
+  remove: function(aDownload)
   {
     if (aDownload.source.isPrivate) {
       return this._privateList.remove(aDownload);
     }
     return this._publicList.remove(aDownload);
   },
 
   // DownloadList view
 
-  onDownloadAdded: function (aDownload)
+  onDownloadAdded: function(aDownload)
   {
     this._downloads.push(aDownload);
     this._notifyAllViews("onDownloadAdded", aDownload);
   },
 
-  onDownloadChanged: function (aDownload)
+  onDownloadChanged: function(aDownload)
   {
     this._notifyAllViews("onDownloadChanged", aDownload);
   },
 
-  onDownloadRemoved: function (aDownload)
+  onDownloadRemoved: function(aDownload)
   {
     let index = this._downloads.indexOf(aDownload);
     if (index != -1) {
       this._downloads.splice(index, 1);
     }
     this._notifyAllViews("onDownloadRemoved", aDownload);
   },
 };
 
 // DownloadSummary
 
 /**
  * Provides an aggregated view on the contents of a DownloadList.
  */
-this.DownloadSummary = function ()
+this.DownloadSummary = function()
 {
   this._downloads = [];
   this._views = new Set();
 }
 
 this.DownloadSummary.prototype = {
   /**
    * Array of Download objects that are currently part of the summary.
@@ -391,17 +391,17 @@ this.DownloadSummary.prototype = {
    *
    * @param aList
    *        Underlying DownloadList whose contents should be summarized.
    *
    * @return {Promise}
    * @resolves When the view on the underlying list has been registered.
    * @rejects JavaScript exception.
    */
-  bindToList: function (aList)
+  bindToList: function(aList)
   {
     if (this._list) {
       throw new Error("bindToList may be called only once.");
     }
 
     return aList.addView(this).then(() => {
       // Set the list reference only after addView has returned, so that we don't
       // send a notification to our views for each download that is added.
@@ -427,17 +427,17 @@ this.DownloadSummary.prototype = {
    *          },
    *        }
    *
    * @return {Promise}
    * @resolves When the view has been registered and the onSummaryChanged
    *           notification has been sent.
    * @rejects JavaScript exception.
    */
-  addView: function (aView)
+  addView: function(aView)
   {
     this._views.add(aView);
 
     if ("onSummaryChanged" in aView) {
       try {
         aView.onSummaryChanged();
       } catch (ex) {
         Cu.reportError(ex);
@@ -453,17 +453,17 @@ this.DownloadSummary.prototype = {
    * @param aView
    *        The view object to remove.
    *
    * @return {Promise}
    * @resolves When the view has been removed.  At this point, the removed view
    *           will not receive any more notifications.
    * @rejects JavaScript exception.
    */
-  removeView: function (aView)
+  removeView: function(aView)
   {
     this._views.delete(aView);
 
     return Promise.resolve();
   },
 
   /**
    * Indicates whether all the downloads are currently stopped.
@@ -489,17 +489,17 @@ this.DownloadSummary.prototype = {
    */
   progressCurrentBytes: 0,
 
   /**
    * This function is called when any change in the list of downloads occurs,
    * and will recalculate the summary and notify the views in case the
    * aggregated properties are different.
    */
-  _onListChanged: function () {
+  _onListChanged: function() {
     let allHaveStopped = true;
     let progressTotalBytes = 0;
     let progressCurrentBytes = 0;
 
     // Recalculate the aggregated state.  See the description of the individual
     // properties for an explanation of the summarization logic.
     for (let download of this._downloads) {
       if (!download.stopped) {
@@ -530,30 +530,30 @@ this.DownloadSummary.prototype = {
       } catch (ex) {
         Cu.reportError(ex);
       }
     }
   },
 
   // DownloadList view
 
-  onDownloadAdded: function (aDownload)
+  onDownloadAdded: function(aDownload)
   {
     this._downloads.push(aDownload);
     if (this._list) {
       this._onListChanged();
     }
   },
 
-  onDownloadChanged: function (aDownload)
+  onDownloadChanged: function(aDownload)
   {
     this._onListChanged();
   },
 
-  onDownloadRemoved: function (aDownload)
+  onDownloadRemoved: function(aDownload)
   {
     let index = this._downloads.indexOf(aDownload);
     if (index != -1) {
       this._downloads.splice(index, 1);
     }
     this._onListChanged();
   },
 };
--- a/toolkit/components/jsdownloads/src/DownloadStore.jsm
+++ b/toolkit/components/jsdownloads/src/DownloadStore.jsm
@@ -45,36 +45,36 @@ Cu.import("resource://gre/modules/XPCOMU
 
 XPCOMUtils.defineLazyModuleGetter(this, "Downloads",
                                   "resource://gre/modules/Downloads.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "OS",
                                   "resource://gre/modules/osfile.jsm")
 XPCOMUtils.defineLazyModuleGetter(this, "Task",
                                   "resource://gre/modules/Task.jsm");
 
-XPCOMUtils.defineLazyGetter(this, "gTextDecoder", function () {
+XPCOMUtils.defineLazyGetter(this, "gTextDecoder", function() {
   return new TextDecoder();
 });
 
-XPCOMUtils.defineLazyGetter(this, "gTextEncoder", function () {
+XPCOMUtils.defineLazyGetter(this, "gTextEncoder", function() {
   return new TextEncoder();
 });
 
 // DownloadStore
 
 /**
  * Handles serialization of Download objects and persistence into a file, so
  * that the state of downloads can be restored across sessions.
  *
  * @param aList
  *        DownloadList object to be populated or serialized.
  * @param aPath
  *        String containing the file path where data should be saved.
  */
-this.DownloadStore = function (aList, aPath)
+this.DownloadStore = function(aList, aPath)
 {
   this.list = aList;
   this.path = aPath;
 }
 
 this.DownloadStore.prototype = {
   /**
    * DownloadList object to be populated or serialized.
--- a/toolkit/components/jsdownloads/src/DownloadUIHelper.jsm
+++ b/toolkit/components/jsdownloads/src/DownloadUIHelper.jsm
@@ -58,36 +58,36 @@ this.DownloadUIHelper = {
    *
    * @param aParent
    *        If specified, should reference the nsIDOMWindow to which the prompts
    *        should be attached.  If omitted, the prompts will be attached to the
    *        most recently active window.
    *
    * @return A DownloadPrompter object.
    */
-  getPrompter: function (aParent)
+  getPrompter: function(aParent)
   {
     return new DownloadPrompter(aParent || null);
   },
 };
 
 /**
  * Returns an object whose keys are the string names from the downloads string
  * bundle, and whose values are either the translated strings or functions
  * returning formatted strings.
  */
-XPCOMUtils.defineLazyGetter(DownloadUIHelper, "strings", function () {
+XPCOMUtils.defineLazyGetter(DownloadUIHelper, "strings", function() {
   let strings = {};
   let sb = Services.strings.createBundle(kStringBundleUrl);
   let enumerator = sb.getSimpleEnumeration();
   while (enumerator.hasMoreElements()) {
     let string = enumerator.getNext().QueryInterface(Ci.nsIPropertyElement);
     let stringName = string.key;
     if (stringName in kStringsRequiringFormatting) {
-      strings[stringName] = function () {
+      strings[stringName] = function() {
         // Convert "arguments" to a real array before calling into XPCOM.
         return sb.formatStringFromName(stringName,
                                        Array.slice(arguments, 0),
                                        arguments.length);
       };
     } else {
       strings[stringName] = string.value;
     }
@@ -99,17 +99,17 @@ XPCOMUtils.defineLazyGetter(DownloadUIHe
 
 /**
  * Allows displaying prompts related to downloads.
  *
  * @param aParent
  *        The nsIDOMWindow to which prompts should be attached, or null to
  *        attach prompts to the most recently active window.
  */
-this.DownloadPrompter = function (aParent)
+this.DownloadPrompter = function(aParent)
 {
   if (AppConstants.MOZ_B2G) {
     // On B2G there is no prompter implementation.
     this._prompter = null;
   } else {
     this._prompter = Services.ww.getNewPrompter(aParent);
   }
 }
@@ -134,17 +134,17 @@ this.DownloadPrompter.prototype = {
    *
    * @param aPath
    *        String containing the full path to the file to be opened.
    *
    * @return {Promise}
    * @resolves Boolean indicating whether the launch operation can continue.
    * @rejects JavaScript exception.
    */
-  confirmLaunchExecutable: function (aPath)
+  confirmLaunchExecutable: function(aPath)
   {
     const kPrefAlertOnEXEOpen = "browser.download.manager.alertOnEXEOpen";
 
     try {
       // Always launch in case we have no prompter implementation.
       if (!this._prompter) {
         return Promise.resolve(true);
       }
--- a/toolkit/components/jsdownloads/src/Downloads.jsm
+++ b/toolkit/components/jsdownloads/src/Downloads.jsm
@@ -133,17 +133,17 @@ this.Downloads = {
    *          isPrivate: Indicates whether the download originated from a
    *                     private window.
    *        }
    *
    * @return {Promise}
    * @resolves When the download has finished successfully.
    * @rejects JavaScript exception if the download failed.
    */
-  fetch: function (aSource, aTarget, aOptions) {
+  fetch: function(aSource, aTarget, aOptions) {
     return this.createDownload({
       source: aSource,
       target: aTarget,
     }).then(function D_SD_onSuccess(aDownload) {
       if (aOptions && ("isPrivate" in aOptions)) {
         aDownload.source.isPrivate = aOptions.isPrivate;
       }
       return aDownload.start();
@@ -164,17 +164,17 @@ this.Downloads = {
    *        are reflected in the Downloads.ALL list, and downloads added to the
    *        Downloads.ALL list are also added to either the Downloads.PUBLIC or
    *        the Downloads.PRIVATE list based on their properties.
    *
    * @return {Promise}
    * @resolves The requested DownloadList or DownloadCombinedList object.
    * @rejects JavaScript exception.
    */
-  getList: function (aType)
+  getList: function(aType)
   {
     if (!this._promiseListsInitialized) {
       this._promiseListsInitialized = Task.spawn(function* () {
         let publicList = new DownloadList();
         let privateList = new DownloadList();
         let combinedList = new DownloadCombinedList(publicList, privateList);
 
         try {
@@ -226,17 +226,17 @@ this.Downloads = {
    *
    * @param aType
    *        This can be Downloads.PUBLIC, Downloads.PRIVATE, or Downloads.ALL.
    *
    * @return {Promise}
    * @resolves The requested DownloadList or DownloadCombinedList object.
    * @rejects JavaScript exception.
    */
-  getSummary: function (aType)
+  getSummary: function(aType)
   {
     if (aType != Downloads.PUBLIC && aType != Downloads.PRIVATE &&
         aType != Downloads.ALL) {
       throw new Error("Invalid aType argument.");
     }
 
     if (!(aType in this._summaries)) {
       this._summaries[aType] = new DownloadSummary();
--- a/toolkit/components/jsdownloads/test/browser/head.js
+++ b/toolkit/components/jsdownloads/test/browser/head.js
@@ -61,17 +61,17 @@ function getTempFile(aLeafName)
   let [base, ext] = DownloadPaths.splitBaseNameAndExtension(aLeafName);
   let leafName = base + "-" + gFileCounter + ext;
   gFileCounter++;
 
   // Get a file reference under the temporary directory for this test file.
   let file = FileUtils.getFile("TmpD", [leafName]);
   ok(!file.exists(), "Temp file does not exist");
 
-  registerCleanupFunction(function () {
+  registerCleanupFunction(function() {
     if (file.exists()) {
       file.remove(false);
     }
   });
 
   return file;
 }
 
--- a/toolkit/components/jsdownloads/test/unit/common_test_Download.js
+++ b/toolkit/components/jsdownloads/test/unit/common_test_Download.js
@@ -300,17 +300,17 @@ add_task(function* test_referrer()
   let sourceUrl = httpUrl("test_referrer.txt");
   let targetPath = getTempFile(TEST_TARGET_FILE_NAME).path;
 
   function cleanup() {
     gHttpServer.registerPathHandler(sourcePath, null);
   }
   do_register_cleanup(cleanup);
 
-  gHttpServer.registerPathHandler(sourcePath, function (aRequest, aResponse) {
+  gHttpServer.registerPathHandler(sourcePath, function(aRequest, aResponse) {
     aResponse.setHeader("Content-Type", "text/plain", false);
 
     do_check_true(aRequest.hasHeader("Referer"));
     do_check_eq(aRequest.getHeader("Referer"), TEST_REFERRER_URL);
   });
   let download = yield Downloads.createDownload({
     source: { url: sourceUrl, referrer: TEST_REFERRER_URL },
     target: targetPath,
@@ -435,17 +435,17 @@ add_task(function* test_final_state_noti
 {
   mustInterruptResponses();
 
   let download = yield promiseStartDownload(httpUrl("interruptible.txt"));
 
   let onchangeNotified = false;
   let lastNotifiedStopped;
   let lastNotifiedProgress;
-  download.onchange = function () {
+  download.onchange = function() {
     onchangeNotified = true;
     lastNotifiedStopped = download.stopped;
     lastNotifiedProgress = download.progress;
   };
 
   // Allow the download to complete.
   let promiseAttempt = download.start();
   continueResponses();
@@ -567,17 +567,17 @@ add_task(function* test_empty_noprogress
   mustInterruptResponses();
   let download;
   if (!gUseLegacySaver) {
     // When testing DownloadCopySaver, we have control over the download, thus
     // we can hook its onchange callback that will be notified when the
     // download starts.
     download = yield promiseNewDownload(sourceUrl);
 
-    download.onchange = function () {
+    download.onchange = function() {
       if (!download.stopped) {
         do_check_false(download.hasProgress);
         do_check_eq(download.currentBytes, 0);
         do_check_eq(download.totalBytes, 0);
       }
     };
 
     download.start().catch(() => {});
@@ -671,17 +671,17 @@ add_task(function* test_cancel_midway()
     download = yield promiseNewDownload(httpUrl("interruptible.txt"));
   } else {
     download = yield promiseStartLegacyDownload(httpUrl("interruptible.txt"),
                                                 options);
   }
 
   // Cancel the download after receiving the first part of the response.
   let deferCancel = Promise.defer();
-  let onchange = function () {
+  let onchange = function() {
     if (!download.stopped && !download.canceled && download.progress == 50) {
       // Cancel the download immediately during the notification.
       deferCancel.resolve(download.cancel());
 
       // The state change happens immediately after calling "cancel", but
       // temporary files or part files may still exist at this point.
       do_check_true(download.canceled);
     }
@@ -856,17 +856,17 @@ add_task(function* test_cancel_midway_re
   do_check_eq(download.target.size, 0);
 
   // Verify that the server sent the response from the start.
   do_check_eq(gMostRecentFirstBytePos, 0);
 
   // The second time, we'll request and obtain the second part of the response,
   // but we still stop when half of the remaining progress is reached.
   let deferMidway = Promise.defer();
-  download.onchange = function () {
+  download.onchange = function() {
     if (!download.stopped && !download.canceled &&
         download.currentBytes == Math.floor(TEST_DATA_SHORT.length * 3 / 2)) {
       download.onchange = null;
       deferMidway.resolve();
     }
   };
 
   mustInterruptResponses();
@@ -1483,17 +1483,17 @@ add_task(function* test_public_and_priva
 
   function cleanup() {
     Services.prefs.clearUserPref("network.cookie.cookieBehavior");
     Services.cookies.removeAll();
     gHttpServer.registerPathHandler(sourcePath, null);
   }
   do_register_cleanup(cleanup);
 
-  gHttpServer.registerPathHandler(sourcePath, function (aRequest, aResponse) {
+  gHttpServer.registerPathHandler(sourcePath, function(aRequest, aResponse) {
     aResponse.setHeader("Content-Type", "text/plain", false);
 
     if (testCount == 0) {
       // No cookies should exist for first public download.
       do_check_false(aRequest.hasHeader("Cookie"));
       aResponse.setHeader("Set-Cookie", "foobar=1", false);
       testCount++;
     } else if (testCount == 1) {
@@ -1554,17 +1554,17 @@ add_task(function* test_with_content_enc
   let sourcePath = "/test_with_content_encoding.txt";
   let sourceUrl = httpUrl("test_with_content_encoding.txt");
 
   function cleanup() {
     gHttpServer.registerPathHandler(sourcePath, null);
   }
   do_register_cleanup(cleanup);
 
-  gHttpServer.registerPathHandler(sourcePath, function (aRequest, aResponse) {
+  gHttpServer.registerPathHandler(sourcePath, function(aRequest, aResponse) {
     aResponse.setHeader("Content-Type", "text/plain", false);
     aResponse.setHeader("Content-Encoding", "gzip", false);
     aResponse.setHeader("Content-Length",
                         "" + TEST_DATA_SHORT_GZIP_ENCODED.length, false);
 
     let bos = new BinaryOutputStream(aResponse.bodyOutputStream);
     bos.writeByteArray(TEST_DATA_SHORT_GZIP_ENCODED,
                        TEST_DATA_SHORT_GZIP_ENCODED.length);
@@ -1590,17 +1590,17 @@ add_task(function* test_with_content_enc
   let sourcePath = "/test_with_content_encoding_ignore_extension.gz";
   let sourceUrl = httpUrl("test_with_content_encoding_ignore_extension.gz");
 
   function cleanup() {
     gHttpServer.registerPathHandler(sourcePath, null);
   }
   do_register_cleanup(cleanup);
 
-  gHttpServer.registerPathHandler(sourcePath, function (aRequest, aResponse) {
+  gHttpServer.registerPathHandler(sourcePath, function(aRequest, aResponse) {
     aResponse.setHeader("Content-Type", "text/plain", false);
     aResponse.setHeader("Content-Encoding", "gzip", false);
     aResponse.setHeader("Content-Length",
                         "" + TEST_DATA_SHORT_GZIP_ENCODED.length, false);
 
     let bos = new BinaryOutputStream(aResponse.bodyOutputStream);
     bos.writeByteArray(TEST_DATA_SHORT_GZIP_ENCODED,
                        TEST_DATA_SHORT_GZIP_ENCODED.length);
@@ -1627,17 +1627,17 @@ add_task(function* test_with_content_enc
 add_task(function* test_cancel_midway_restart_with_content_encoding()
 {
   mustInterruptResponses();
 
   let download = yield promiseStartDownload(httpUrl("interruptible_gzip.txt"));
 
   // The first time, cancel the download midway.
   let deferCancel = Promise.defer();
-  let onchange = function () {
+  let onchange = function() {
     if (!download.stopped && !download.canceled &&
         download.currentBytes == TEST_DATA_SHORT_GZIP_ENCODED_FIRST.length) {
       deferCancel.resolve(download.cancel());
     }
   };
 
   // Register for the notification, but also call the function directly in
   // case the download already reached the expected progress.
@@ -2387,17 +2387,17 @@ add_task(function* test_platform_integra
         source: { url: httpUrl("source.txt"), isPrivate },
         target: targetFile,
       });
       download.start().catch(() => {});
     }
 
     // Wait for the whenSucceeded promise to be resolved first.
     // downloadDone should be called before the whenSucceeded promise is resolved.
-    yield download.whenSucceeded().then(function () {
+    yield download.whenSucceeded().then(function() {
       do_check_true(downloadDoneCalled);
       do_check_true(downloadWatcherNotified);
     });
 
     // Then, wait for the promise returned by "start" to be resolved.
     yield promiseDownloadStopped(download);
 
     yield promiseVerifyTarget(download.target, TEST_DATA_SHORT);
--- a/toolkit/components/jsdownloads/test/unit/head.js
+++ b/toolkit/components/jsdownloads/test/unit/head.js
@@ -131,17 +131,17 @@ function getTempFile(aLeafName)
   let [base, ext] = DownloadPaths.splitBaseNameAndExtension(aLeafName);
   let leafName = base + "-" + gFileCounter + ext;
   gFileCounter++;
 
   // Get a file reference under the temporary directory for this test file.
   let file = FileUtils.getFile("TmpD", [leafName]);
   do_check_false(file.exists());
 
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     try {
       file.remove(false)
     } catch (e) {
       if (!(e instanceof Components.Exception &&
             (e.result == Cr.NS_ERROR_FILE_ACCESS_DENIED ||
              e.result == Cr.NS_ERROR_FILE_TARGET_DOES_NOT_EXIST ||
              e.result == Cr.NS_ERROR_FILE_NOT_FOUND))) {
         throw e;
@@ -197,30 +197,30 @@ function promiseTimeout(aTime)
 function promiseWaitForVisit(aUrl)
 {
   let deferred = Promise.defer();
 
   let uri = NetUtil.newURI(aUrl);
 
   PlacesUtils.history.addObserver({
     QueryInterface: XPCOMUtils.generateQI([Ci.nsINavHistoryObserver]),
-    onBeginUpdateBatch: function () {},
-    onEndUpdateBatch: function () {},
-    onVisit: function (aURI, aVisitID, aTime, aSessionID, aReferringID,
-                       aTransitionType, aGUID, aHidden) {
+    onBeginUpdateBatch: function() {},
+    onEndUpdateBatch: function() {},
+    onVisit: function(aURI, aVisitID, aTime, aSessionID, aReferringID,
+                      aTransitionType, aGUID, aHidden) {
       if (aURI.equals(uri)) {
         PlacesUtils.history.removeObserver(this);
         deferred.resolve([aTime, aTransitionType]);
       }
     },
-    onTitleChanged: function () {},
-    onDeleteURI: function () {},
-    onClearHistory: function () {},
-    onPageChanged: function () {},
-    onDeleteVisits: function () {},
+    onTitleChanged: function() {},
+    onDeleteURI: function() {},
+    onClearHistory: function() {},
+    onPageChanged: function() {},
+    onDeleteVisits: function() {},
   }, false);
 
   return deferred.promise;
 }
 
 /**
  * Check browsing history to see whether the given URI has been visited.
  *
@@ -230,17 +230,17 @@ function promiseWaitForVisit(aUrl)
  * @return {Promise}
  * @resolves Boolean indicating whether the URI has been visited.
  * @rejects JavaScript exception.
  */
 function promiseIsURIVisited(aUrl) {
   let deferred = Promise.defer();
 
   PlacesUtils.asyncHistory.isURIVisited(NetUtil.newURI(aUrl),
-    function (aURI, aIsVisited) {
+    function(aURI, aIsVisited) {
       deferred.resolve(aIsVisited);
     });
 
   return deferred.promise;
 }
 
 /**
  * Creates a new Download object, setting a temporary file as the target.
@@ -332,21 +332,21 @@ function promiseStartLegacyDownload(aSou
   persist.persistFlags &= ~Ci.nsIWebBrowserPersist.PERSIST_FLAGS_NO_CONVERSION;
   persist.persistFlags |=
     Ci.nsIWebBrowserPersist.PERSIST_FLAGS_AUTODETECT_APPLY_CONVERSION;
 
   let transfer = Cc["@mozilla.org/transfer;1"].createInstance(Ci.nsITransfer);
 
   let deferred = Promise.defer();
 
-  Downloads.getList(Downloads.ALL).then(function (aList) {
+  Downloads.getList(Downloads.ALL).then(function(aList) {
     // Temporarily register a view that will get notified when the download we
     // are controlling becomes visible in the list of downloads.
     aList.addView({
-      onDownloadAdded: function (aDownload) {
+      onDownloadAdded: function(aDownload) {
         aList.removeView(this).then(null, do_report_unexpected_exception);
 
         // Remove the download to keep the list empty for the next test.  This
         // also allows the caller to register the "onchange" event directly.
         let promise = aList.remove(aDownload);
 
         // When the download object is ready, make it available to the caller.
         promise.then(() => deferred.resolve(aDownload),
@@ -385,21 +385,21 @@ function promiseStartLegacyDownload(aSou
  * @rejects Never.  The current test fails in case of exceptions.
  */
 function promiseStartExternalHelperAppServiceDownload(aSourceUrl) {
   let sourceURI = NetUtil.newURI(aSourceUrl ||
                                  httpUrl("interruptible_resumable.txt"));
 
   let deferred = Promise.defer();
 
-  Downloads.getList(Downloads.PUBLIC).then(function (aList) {
+  Downloads.getList(Downloads.PUBLIC).then(function(aList) {
     // Temporarily register a view that will get notified when the download we
     // are controlling becomes visible in the list of downloads.
     aList.addView({
-      onDownloadAdded: function (aDownload) {
+      onDownloadAdded: function(aDownload) {
         aList.removeView(this).then(null, do_report_unexpected_exception);
 
         // Remove the download to keep the list empty for the next test.  This
         // also allows the caller to register the "onchange" event directly.
         let promise = aList.remove(aDownload);
 
         // When the download object is ready, make it available to the caller.
         promise.then(() => deferred.resolve(aDownload),
@@ -411,31 +411,31 @@ function promiseStartExternalHelperAppSe
       uri: sourceURI,
       loadUsingSystemPrincipal: true
     });
 
     // Start the actual download process.
     channel.asyncOpen2({
       contentListener: null,
 
-      onStartRequest: function (aRequest, aContext)
+      onStartRequest: function(aRequest, aContext)
       {
         let requestChannel = aRequest.QueryInterface(Ci.nsIChannel);
         this.contentListener = gExternalHelperAppService.doContent(
                                      requestChannel.contentType, aRequest, null, true);
         this.contentListener.onStartRequest(aRequest, aContext);
       },
 
-      onStopRequest: function (aRequest, aContext, aStatusCode)
+      onStopRequest: function(aRequest, aContext, aStatusCode)
       {
         this.contentListener.onStopRequest(aRequest, aContext, aStatusCode);
       },
 
-      onDataAvailable: function (aRequest, aContext, aInputStream, aOffset,
-                                 aCount)
+      onDataAvailable: function(aRequest, aContext, aInputStream, aOffset,
+                                aCount)
       {
         this.contentListener.onDataAvailable(aRequest, aContext, aInputStream,
                                              aOffset, aCount);
       },
     });
   }.bind(this)).then(null, do_report_unexpected_exception);
 
   return deferred.promise;
@@ -451,17 +451,17 @@ function promiseStartExternalHelperAppSe
  * @return {Promise}
  * @resolves When the download has reached half of its progress.
  * @rejects Never.
  */
 function promiseDownloadMidway(aDownload) {
   let deferred = Promise.defer();
 
   // Wait for the download to reach half of its progress.
-  let onchange = function () {
+  let onchange = function() {
     if (!aDownload.stopped && !aDownload.canceled && aDownload.progress == 50) {
       aDownload.onchange = null;
       deferred.resolve();
     }
   };
 
   // Register for the notification, but also call the function directly in
   // case the download already reached the expected progress.
@@ -571,20 +571,20 @@ function promiseVerifyContents(aPath, aE
  *
  * @returns nsIServerSocket that listens for connections.  Call its "close"
  *          method to stop listening and free the server port.
  */
 function startFakeServer()
 {
   let serverSocket = new ServerSocket(-1, true, -1);
   serverSocket.asyncListen({
-    onSocketAccepted: function (aServ, aTransport) {
+    onSocketAccepted: function(aServ, aTransport) {
       aTransport.close(Cr.NS_BINDING_ABORTED);
     },
-    onStopListening: function () { },
+    onStopListening: function() { },
   });
   return serverSocket;
 }
 
 /**
  * This is an internal reference that should not be used directly by tests.
  */
 var _gDeferResponses = Promise.defer();
@@ -637,17 +637,17 @@ function continueResponses()
  *        This function is called when the response is received, with the
  *        aRequest and aResponse arguments of the server.
  * @param aSecondPartFn
  *        This function is called with the aRequest and aResponse arguments of
  *        the server, when the continueResponses function is called.
  */
 function registerInterruptibleHandler(aPath, aFirstPartFn, aSecondPartFn)
 {
-  gHttpServer.registerPathHandler(aPath, function (aRequest, aResponse) {
+  gHttpServer.registerPathHandler(aPath, function(aRequest, aResponse) {
     do_print("Interruptible request started.");
 
     // Process the first part of the response.
     aResponse.processAsync();
     aFirstPartFn(aRequest, aResponse);
 
     // Wait on the current deferred object, then finish the request.
     _gDeferResponses.promise.then(function RIH_onSuccess() {
@@ -690,17 +690,17 @@ add_task(function test_common_initialize
       gHttpServer.stop(resolve);
     });
   });
 
   // Cache locks might prevent concurrent requests to the same resource, and
   // this may block tests that use the interruptible handlers.
   Services.prefs.setBoolPref("browser.cache.disk.enable", false);
   Services.prefs.setBoolPref("browser.cache.memory.enable", false);
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     Services.prefs.clearUserPref("browser.cache.disk.enable");
     Services.prefs.clearUserPref("browser.cache.memory.enable");
   });
 
   registerInterruptibleHandler("/interruptible.txt",
     function firstPart(aRequest, aResponse) {
       aResponse.setHeader("Content-Type", "text/plain", false);
       aResponse.setHeader("Content-Length", "" + (TEST_DATA_SHORT.length * 2),
@@ -764,29 +764,29 @@ add_task(function test_common_initialize
                          TEST_DATA_SHORT_GZIP_ENCODED_FIRST.length);
     }, function secondPart(aRequest, aResponse) {
       let bos =  new BinaryOutputStream(aResponse.bodyOutputStream);
       bos.writeByteArray(TEST_DATA_SHORT_GZIP_ENCODED_SECOND,
                          TEST_DATA_SHORT_GZIP_ENCODED_SECOND.length);
     });
 
   gHttpServer.registerPathHandler("/shorter-than-content-length-http-1-1.txt",
-    function (aRequest, aResponse) {
+    function(aRequest, aResponse) {
       aResponse.processAsync();
       aResponse.setStatusLine("1.1", 200, "OK");
       aResponse.setHeader("Content-Type", "text/plain", false);
       aResponse.setHeader("Content-Length", "" + (TEST_DATA_SHORT.length * 2),
                           false);
       aResponse.write(TEST_DATA_SHORT);
       aResponse.finish();
     });
 
   // This URL will emulate being blocked by Windows Parental controls
   gHttpServer.registerPathHandler("/parentalblocked.zip",
-    function (aRequest, aResponse) {
+    function(aRequest, aResponse) {
       aResponse.setStatusLine(aRequest.httpVersion, 450,
                               "Blocked by Windows Parental Controls");
     });
 
   // During unit tests, most of the functions that require profile access or
   // operating system features will be disabled. Individual tests may override
   // them again to check for specific behaviors.
   Integration.downloads.register(base => ({
--- a/toolkit/components/jsdownloads/test/unit/test_DownloadImport.js
+++ b/toolkit/components/jsdownloads/test/unit/test_DownloadImport.js
@@ -164,32 +164,32 @@ function promiseEntityID(aUrl) {
   let deferred = Promise.defer();
   let entityID = "";
   let channel = NetUtil.newChannel({
     uri: NetUtil.newURI(aUrl),
     loadUsingSystemPrincipal: true
   });
 
   channel.asyncOpen2({
-    onStartRequest: function (aRequest) {
+    onStartRequest: function(aRequest) {
       if (aRequest instanceof Ci.nsIResumableChannel) {
         entityID = aRequest.entityID;
       }
       aRequest.cancel(Cr.NS_BINDING_ABORTED);
     },
 
-    onStopRequest: function (aRequest, aContext, aStatusCode) {
+    onStopRequest: function(aRequest, aContext, aStatusCode) {
       if (aStatusCode == Cr.NS_BINDING_ABORTED) {
         deferred.resolve(entityID);
       } else {
         deferred.reject("Unexpected status code received");
       }
     },
 
-    onDataAvailable: function () {}
+    onDataAvailable: function() {}
   });
 
   return deferred.promise;
 }
 
 /**
  * Gets a file path to a temporary writeable download target, in the
  * correct format as expected to be stored in the downloads database,
--- a/toolkit/components/jsdownloads/test/unit/test_DownloadIntegration.js
+++ b/toolkit/components/jsdownloads/test/unit/test_DownloadIntegration.js
@@ -210,17 +210,17 @@ add_task(function* test_getTemporaryDown
  * Re-enables the default observers for the following tests.
  *
  * This takes effect the first time a DownloadList object is created, and lasts
  * until this test file has completed.
  */
 add_task(function* test_observers_setup()
 {
   DownloadIntegration.allowObservers = true;
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     DownloadIntegration.allowObservers = false;
   });
 });
 
 /**
  * Tests notifications prompts when observers are notified if there are public
  * and private active downloads.
  */
--- a/toolkit/components/jsdownloads/test/unit/test_DownloadList.js
+++ b/toolkit/components/jsdownloads/test/unit/test_DownloadList.js
@@ -51,17 +51,17 @@ function promiseExpirableDownloadVisit(a
       }]
     },
     {
       handleError: function handleError(aResultCode, aPlaceInfo) {
         let ex = new Components.Exception("Unexpected error in adding visits.",
                                           aResultCode);
         deferred.reject(ex);
       },
-      handleResult: function () {},
+      handleResult: function() {},
       handleCompletion: function handleCompletion() {
         deferred.resolve();
       }
     });
   return deferred.promise;
 }
 
 // Tests
@@ -187,17 +187,17 @@ add_task(function* test_notifications_ad
       target: getTempFile(TEST_TARGET_FILE_NAME).path,
     });
     yield list.add(downloadOne);
     yield list.add(downloadTwo);
 
     // Check that we receive add notifications for existing elements.
     let addNotifications = 0;
     let viewOne = {
-      onDownloadAdded: function (aDownload) {
+      onDownloadAdded: function(aDownload) {
         // The first download to be notified should be the first that was added.
         if (addNotifications == 0) {
           do_check_eq(aDownload, downloadOne);
         } else if (addNotifications == 1) {
           do_check_eq(aDownload, downloadTwo);
         }
         addNotifications++;
       },
@@ -207,17 +207,17 @@ add_task(function* test_notifications_ad
 
     // Check that we receive add notifications for new elements.
     yield list.add(yield promiseNewDownload());
     do_check_eq(addNotifications, 3);
 
     // Check that we receive remove notifications.
     let removeNotifications = 0;
     let viewTwo = {
-      onDownloadRemoved: function (aDownload) {
+      onDownloadRemoved: function(aDownload) {
         do_check_eq(aDownload, downloadOne);
         removeNotifications++;
       },
     };
     yield list.addView(viewTwo);
     yield list.remove(downloadOne);
     do_check_eq(removeNotifications, 1);
 
@@ -252,17 +252,17 @@ add_task(function* test_notifications_ch
       target: getTempFile(TEST_TARGET_FILE_NAME).path,
     });
     yield list.add(downloadOne);
     yield list.add(downloadTwo);
 
     // Check that we receive change notifications.
     let receivedOnDownloadChanged = false;
     yield list.addView({
-      onDownloadChanged: function (aDownload) {
+      onDownloadChanged: function(aDownload) {
         do_check_eq(aDownload, downloadOne);
         receivedOnDownloadChanged = true;
       },
     });
     yield downloadOne.start();
     do_check_true(receivedOnDownloadChanged);
 
     // We should not receive change notifications after a download is removed.
@@ -280,28 +280,28 @@ add_task(function* test_notifications_th
 {
   let list = yield promiseNewList();
 
   // Check that we receive change notifications.
   let receivedOnDownloadAdded = false;
   let receivedOnDownloadChanged = false;
   let receivedOnDownloadRemoved = false;
   let view = {
-    onDownloadAdded: function () {
+    onDownloadAdded: function() {
       do_check_eq(this, view);
       receivedOnDownloadAdded = true;
     },
-    onDownloadChanged: function () {
+    onDownloadChanged: function() {
       // Only do this check once.
       if (!receivedOnDownloadChanged) {
         do_check_eq(this, view);
         receivedOnDownloadChanged = true;
       }
     },
-    onDownloadRemoved: function () {
+    onDownloadRemoved: function() {
       do_check_eq(this, view);
       receivedOnDownloadRemoved = true;
     },
   };
   yield list.addView(view);
 
   let download = yield promiseNewDownload();
   yield list.add(download);
@@ -331,17 +331,17 @@ add_task(function* test_history_expirati
 
   let list = yield promiseNewList();
   let downloadOne = yield promiseNewDownload();
   let downloadTwo = yield promiseNewDownload(httpUrl("interruptible.txt"));
 
   let deferred = Promise.defer();
   let removeNotifications = 0;
   let downloadView = {
-    onDownloadRemoved: function (aDownload) {
+    onDownloadRemoved: function(aDownload) {
       if (++removeNotifications == 2) {
         deferred.resolve();
       }
     },
   };
   yield list.addView(downloadView);
 
   // Work with one finished download and one canceled download.
@@ -378,17 +378,17 @@ add_task(function* test_history_clear()
   let downloadOne = yield promiseNewDownload();
   let downloadTwo = yield promiseNewDownload();
   yield list.add(downloadOne);
   yield list.add(downloadTwo);
 
   let deferred = Promise.defer();
   let removeNotifications = 0;
   let downloadView = {
-    onDownloadRemoved: function (aDownload) {
+    onDownloadRemoved: function(aDownload) {
       if (++removeNotifications == 2) {
         deferred.resolve();
       }
     },
   };
   yield list.addView(downloadView);
 
   yield downloadOne.start();
@@ -414,17 +414,17 @@ add_task(function* test_removeFinished()
   yield list.add(downloadOne);
   yield list.add(downloadTwo);
   yield list.add(downloadThree);
   yield list.add(downloadFour);
 
   let deferred = Promise.defer();
   let removeNotifications = 0;
   let downloadView = {
-    onDownloadRemoved: function (aDownload) {
+    onDownloadRemoved: function(aDownload) {
       do_check_true(aDownload == downloadOne ||
                     aDownload == downloadTwo ||
                     aDownload == downloadThree);
       do_check_true(removeNotifications < 3);
       if (++removeNotifications == 3) {
         deferred.resolve();
       }
     },
@@ -550,15 +550,15 @@ add_task(function* test_DownloadSummary_
   let summary = yield Downloads.getSummary(Downloads.ALL);
 
   let download = yield promiseNewDownload();
   yield list.add(download);
 
   // Check that we receive change notifications.
   let receivedOnSummaryChanged = false;
   yield summary.addView({
-    onSummaryChanged: function () {
+    onSummaryChanged: function() {
       receivedOnSummaryChanged = true;
     },
   });
   yield download.start();
   do_check_true(receivedOnSummaryChanged);
 });
--- a/toolkit/components/jsdownloads/test/unit/test_DownloadStore.js
+++ b/toolkit/components/jsdownloads/test/unit/test_DownloadStore.js
@@ -25,17 +25,17 @@ XPCOMUtils.defineLazyModuleGetter(this, 
  *        temporary file is deleted when the test file execution finishes.
  *
  * @return {Promise}
  * @resolves Array [ Newly created DownloadList , associated DownloadStore ].
  * @rejects JavaScript exception.
  */
 function promiseNewListAndStore(aStorePath)
 {
-  return promiseNewList().then(function (aList) {
+  return promiseNewList().then(function(aList) {
     let path = aStorePath || getTempFile(TEST_STORE_FILE_NAME).path;
     let store = new DownloadStore(aList, path);
     return [aList, store];
   });
 }
 
 // Tests
 
--- a/toolkit/components/microformats/microformat-shiv.js
+++ b/toolkit/components/microformats/microformat-shiv.js
@@ -4,37 +4,37 @@
    Built: 2016-03-02 10:03 - http://microformat-shiv.com
    Copyright (c) 2016 Glenn Jones
    Licensed MIT
 */
 
 
 var Microformats; // jshint ignore:line
 
-(function (root, factory) {
+(function(root, factory) {
     if (typeof define === 'function' && define.amd) {
         define([], factory);
     } else if (typeof exports === 'object') {
         module.exports = factory();
     } else {
         root.Microformats = factory();
   }
-}(this, function () {
+}(this, function() {
 
     var modules = {};
 
 
     modules.version = '1.4.0';
     modules.livingStandard = '2015-09-25T12:26:04Z';
 
     /**
      * constructor
      *
      */
-    modules.Parser = function () {
+    modules.Parser = function() {
         this.rootPrefix = 'h-';
         this.propertyPrefixes = ['p-', 'dt-', 'u-', 'e-'];
         this.excludeTags = ['br', 'hr'];
     };
 
 
     // create objects incase the v1 map modules don't load
     modules.maps = (modules.maps) ? modules.maps : {};
@@ -270,17 +270,17 @@ var Microformats; // jshint ignore:line
         /**
          * internal parse to get parent microformats by walking up the tree
          *
          * @param  {DOM Node} node
          * @param  {Object} options
          * @param  {Int} recursive
          * @return {Object}
          */
-        getParentTreeWalk: function (node, options, recursive) {
+        getParentTreeWalk: function(node, options, recursive) {
             options = (options) ? options : {};
 
             // recursive calls
             if (recursive === undefined) {
                 if (node.parentNode && node.nodeName !== 'HTML') {
                     return this.getParentTreeWalk(node.parentNode, options, true);
                 }
                 return this.formatEmpty();
@@ -2362,17 +2362,17 @@ var Microformats; // jshint ignore:line
          * a sort function - to sort objects in an array by a given property
          *
          * @param  {String} property
          * @param  {Boolean} reverse
          * @return {Int}
          */
         sortObjects: function(property, reverse) {
             reverse = (reverse) ? -1 : 1;
-            return function (a, b) {
+            return function(a, b) {
                 a = a[property];
                 b = b[property];
                 if (a < b) {
                     return reverse * -1;
                 }
                 if (a > b) {
                     return reverse * 1;
                 }
@@ -2390,17 +2390,17 @@ var Microformats; // jshint ignore:line
         rootNode: null,
 
 
          /**
          * gets DOMParser object
          *
          * @return {Object || undefined}
          */
-        getDOMParser: function () {
+        getDOMParser: function() {
             if (typeof DOMParser === "undefined") {
                 try {
                     return Components.classes["@mozilla.org/xmlextras/domparser;1"]
                         .createInstance(Components.interfaces.nsIDOMParser);
                 } catch (e) {
                     return undefined;
                 }
             } else {
@@ -2878,17 +2878,17 @@ var Microformats; // jshint ignore:line
 
 
         /**
          * get the child index of a node. Used to create a node path
          *
          *   @param  {DOM Node} node
          *   @return {Int}
          */
-        getChildIndex: function (node) {
+        getChildIndex: function(node) {
             var parent = node.parentNode,
                 i = -1,
                 child;
             while (parent && (child = parent.childNodes[++i])) {
                  if (child === node) {
                      return i;
                  }
             }
@@ -2897,17 +2897,17 @@ var Microformats; // jshint ignore:line
 
 
         /**
          * get a node's path
          *
          *   @param  {DOM Node} node
          *   @return {Array}
          */
-        getNodePath: function  (node) {
+        getNodePath: function(node) {
             var parent = node.parentNode,
                 path = [],
                 index = this.getChildIndex(node);
 
           if (parent && (path = this.getNodePath(parent))) {
                if (index > -1) {
                    path.push(index);
                }
@@ -2918,17 +2918,17 @@ var Microformats; // jshint ignore:line
 
         /**
          * get a node from a path.
          *
          *   @param  {DOM document} document
          *   @param  {Array} path
          *   @return {DOM Node}
          */
-        getNodeByPath: function (document, path) {
+        getNodeByPath: function(document, path) {
             var node = document.documentElement,
                 i = 0,
                 index;
           while ((index = path[++i]) > -1) {
               node = node.childNodes[index];
           }
           return node;
         },
@@ -3037,17 +3037,17 @@ var Microformats; // jshint ignore:line
     /**
      * constructor
      * parses text to find just the date element of an ISO date/time string i.e. 2008-05-01
      *
      * @param  {String} dateString
      * @param  {String} format
      * @return {String}
      */
-    modules.ISODate = function ( dateString, format ) {
+    modules.ISODate = function( dateString, format ) {
         this.clear();
 
         this.format = (format) ? format : 'auto'; // auto or W3C or RFC3339 or HTML5
         this.setFormatSep();
 
         // optional should be full iso date/time string
         if (arguments[0]) {
             this.parse(dateString, format);
@@ -3665,17 +3665,17 @@ var Microformats; // jshint ignore:line
        /**
          * concatenate an array of date and time text fragments to create an ISODate object
          * used for microformat value and value-title rules
          *
          * @param  {Array} arr ( Array of Strings )
          * @param  {String} format ( Modules.ISODate profile format )
          * @return {Object} Modules.ISODate
          */
-        concatFragments: function (arr, format) {
+        concatFragments: function(arr, format) {
             var out = new modules.ISODate(),
                 i = 0,
                 value = '';
 
             // if the fragment already contains a full date just return it once
             if (arr[0].toUpperCase().match('T')) {
                 return new modules.ISODate(arr[0], format);
             }
@@ -3716,17 +3716,17 @@ var Microformats; // jshint ignore:line
 
 
        /**
          * parses text by splitting it into an array of time and timezone strings
          *
          * @param  {String} text
          * @return {Array} Modules.ISODate
          */
-        splitTimeAndZone: function ( text ) {
+        splitTimeAndZone: function( text ) {
            var out = [text],
                chars = ['-', '+', 'z', 'Z'],
                i = chars.length;
 
             while (i--) {
               if (text.indexOf(chars[i]) > -1) {
                   out[0] = text.slice( 0, text.indexOf(chars[i]) );
                   out.push( text.slice( text.indexOf(chars[i]) ) );
--- a/toolkit/components/microformats/update/update.js
+++ b/toolkit/components/microformats/update/update.js
@@ -152,17 +152,17 @@ function getLastCommitDate( repo, callba
 
 	var options = {
 	  url: 'https://api.github.com/repos/' + repo + '/commits?per_page=1',
 	  headers: {
 	    'User-Agent': 'request'
 	  }
 	};
 
-	request(options, function (error, response, body) {
+	request(options, function(error, response, body) {
 	  if (!error && response.statusCode == 200) {
 		var date = null,
 			json = JSON.parse(body);
 			if (json && json.length && json[0].commit && json[0].commit.author ) {
 				date = json[0].commit.author.date;
 			}
 	    callback(null, date);
 	  } else {
@@ -184,17 +184,17 @@ function getLastBuildState( repo, callba
 	var options = {
 	  url: 'https://api.travis-ci.org/repos/' + repo,
 	  headers: {
 	    'User-Agent': 'request',
 		'Accept': 'application/vnd.travis-ci.2+json'
 	  }
 	};
 
-	request(options, function (error, response, body) {
+	request(options, function(error, response, body) {
 	  if (!error && response.statusCode == 200) {
 		var buildState = null,
 			json = JSON.parse(body);
 			if (json && json.repo &&  json.repo.last_build_state ) {
 				buildState = json.repo.last_build_state;
 			}
 	    callback(null, buildState);
 	  } else {
--- a/toolkit/components/passwordmgr/LoginImport.jsm
+++ b/toolkit/components/passwordmgr/LoginImport.jsm
@@ -38,17 +38,17 @@ XPCOMUtils.defineLazyModuleGetter(this, 
  * Provides an object that has a method to import login-related data from the
  * previous SQLite storage format.
  *
  * @param aStore
  *        LoginStore object where imported data will be added.
  * @param aPath
  *        String containing the file path of the SQLite login database.
  */
-this.LoginImport = function (aStore, aPath) {
+this.LoginImport = function(aStore, aPath) {
   this.store = aStore;
   this.path = aPath;
 };
 
 this.LoginImport.prototype = {
   /**
    * LoginStore object where imported data will be added.
    */
--- a/toolkit/components/passwordmgr/LoginManagerContent.jsm
+++ b/toolkit/components/passwordmgr/LoginManagerContent.jsm
@@ -1027,17 +1027,17 @@ var LoginManagerContent = {
       var maxPasswordLen = Number.MAX_VALUE;
 
       // If attribute wasn't set, default is -1.
       if (usernameField && usernameField.maxLength >= 0)
         maxUsernameLen = usernameField.maxLength;
       if (passwordField.maxLength >= 0)
         maxPasswordLen = passwordField.maxLength;
 
-      var logins = foundLogins.filter(function (l) {
+      var logins = foundLogins.filter(function(l) {
         var fit = (l.username.length <= maxUsernameLen &&
                    l.password.length <= maxPasswordLen);
         if (!fit)
           log("Ignored", l.username, "login: won't fit");
 
         return fit;
       }, this);
 
@@ -1229,17 +1229,17 @@ var LoginUtils = {
     if (uriString == "")
       uriString = form.baseURI; // ala bug 297761
 
     return this._getPasswordOrigin(uriString, true);
   },
 };
 
 // nsIAutoCompleteResult implementation
-function UserAutoCompleteResult (aSearchString, matchingLogins, {isSecure, messageManager, isPasswordField}) {
+function UserAutoCompleteResult(aSearchString, matchingLogins, {isSecure, messageManager, isPasswordField}) {
   this.searchString = aSearchString;
 
   this._stringBundle = Services.strings.createBundle("chrome://passwordmgr/locale/passwordmgr.properties");
   this._dateAndTimeFormatter = new Intl.DateTimeFormat(undefined,
                               { day: "numeric", month: "short", year: "numeric" });
 
   this._messageManager = messageManager;
   this._matchingLogins = matchingLogins;
--- a/toolkit/components/passwordmgr/LoginManagerParent.jsm
+++ b/toolkit/components/passwordmgr/LoginManagerParent.jsm
@@ -52,17 +52,17 @@ var LoginManagerParent = {
       const { LoginRecipesParent } = Cu.import("resource://gre/modules/LoginRecipes.jsm", {});
       this._recipeManager = new LoginRecipesParent({
         defaults: Services.prefs.getComplexValue("signon.recipes.path", Ci.nsISupportsString).data,
       });
       return this._recipeManager.initializationPromise;
     });
   },
 
-  receiveMessage: function (msg) {
+  receiveMessage: function(msg) {
     let data = msg.data;
     switch (msg.name) {
       case "RemoteLogins:findLogins": {
         // TODO Verify msg.target's principals against the formOrigin?
         this.sendLoginDataToChild(data.options.showMasterPassword,
                                   data.formOrigin,
                                   data.actionOrigin,
                                   data.requestId,
@@ -170,17 +170,17 @@ var LoginManagerParent = {
     // processing this form until the user handles the prompt.
     if (Services.logins.uiBusy) {
       log("deferring sendLoginDataToChild for", formOrigin);
       let self = this;
       let observer = {
         QueryInterface: XPCOMUtils.generateQI([Ci.nsIObserver,
                                                Ci.nsISupportsWeakReference]),
 
-        observe: function (subject, topic, data) {
+        observe: function(subject, topic, data) {
           log("Got deferred sendLoginDataToChild notification:", topic);
           // Only run observer once.
           Services.obs.removeObserver(this, "passwordmgr-crypto-login");
           Services.obs.removeObserver(this, "passwordmgr-crypto-loginCanceled");
           if (topic == "passwordmgr-crypto-loginCanceled") {
             target.sendAsyncMessage("RemoteLogins:loginsFound", {
               requestId: requestId,
               logins: [],
--- a/toolkit/components/passwordmgr/LoginRecipes.jsm
+++ b/toolkit/components/passwordmgr/LoginRecipes.jsm
@@ -92,17 +92,17 @@ LoginRecipesParent.prototype = {
 
     if (this._defaults) {
       let channel = NetUtil.newChannel({uri: NetUtil.newURI(this._defaults, "UTF-8"),
                                         loadUsingSystemPrincipal: true});
       channel.contentType = "application/json";
 
       try {
         this.initializationPromise = new Promise(function(resolve) {
-          NetUtil.asyncFetch(channel, function (stream, result) {
+          NetUtil.asyncFetch(channel, function(stream, result) {
             if (!Components.isSuccessCode(result)) {
               throw new Error("Error fetching recipe file:" + result);
             }
             let count = stream.available();
             let data = NetUtil.readInputStreamToString(stream, count, { charset: "UTF-8" });
             resolve(JSON.parse(data));
           });
         }).then(recipes => {
--- a/toolkit/components/passwordmgr/LoginStore.jsm
+++ b/toolkit/components/passwordmgr/LoginStore.jsm
@@ -117,17 +117,17 @@ LoginStore.prototype._dataPostProcessor 
   data.version = kDataVersion;
 
   return data;
 };
 
 /**
  * Migrates disabled hosts to the permission manager.
  */
-LoginStore.prototype._migrateDisabledHosts = function (data) {
+LoginStore.prototype._migrateDisabledHosts = function(data) {
   for (let host of data.disabledHosts) {
     try {
       let uri = Services.io.newURI(host, null, null);
       Services.perms.add(uri, PERMISSION_SAVE_LOGINS, Services.perms.DENY_ACTION);
     } catch (e) {
       Cu.reportError(e);
     }
   }
--- a/toolkit/components/passwordmgr/crypto-SDR.js
+++ b/toolkit/components/passwordmgr/crypto-SDR.js
@@ -49,17 +49,17 @@ LoginManagerCrypto_SDR.prototype = {
 
   _utfConverterReset : function() {
     this.__utfConverter = null;
   },
 
   _uiBusy : false,
 
 
-  init : function () {
+  init : function() {
     // Check to see if the internal PKCS#11 token has been initialized.
     // If not, set a blank password.
     let tokenDB = Cc["@mozilla.org/security/pk11tokendb;1"].
                   getService(Ci.nsIPK11TokenDB);
 
     let token = tokenDB.getInternalKeyToken();
     if (token.needsUserInit) {
       this.log("Initializing key3.db with default blank password.");
@@ -71,17 +71,17 @@ LoginManagerCrypto_SDR.prototype = {
   /*
    * encrypt
    *
    * Encrypts the specified string, using the SecretDecoderRing.
    *
    * Returns the encrypted string, or throws an exception if there was a
    * problem.
    */
-  encrypt : function (plainText) {
+  encrypt : function(plainText) {
     let cipherText = null;
 
     let wasLoggedIn = this.isLoggedIn;
     let canceledMP = false;
 
     this._uiBusy = true;
     try {
       let plainOctet = this._utfConverter.ConvertFromUnicode(plainText);
@@ -112,17 +112,17 @@ LoginManagerCrypto_SDR.prototype = {
   /*
    * decrypt
    *
    * Decrypts the specified string, using the SecretDecoderRing.
    *
    * Returns the decrypted string, or throws an exception if there was a
    * problem.
    */
-  decrypt : function (cipherText) {
+  decrypt : function(cipherText) {
     let plainText = null;
 
     let wasLoggedIn = this.isLoggedIn;
     let canceledMP = false;
 
     this._uiBusy = true;
     try {
       let plainOctet;
--- a/toolkit/components/passwordmgr/nsLoginInfo.js
+++ b/toolkit/components/passwordmgr/nsLoginInfo.js
@@ -24,35 +24,35 @@ nsLoginInfo.prototype = {
   hostname      : null,
   formSubmitURL : null,
   httpRealm     : null,
   username      : null,
   password      : null,
   usernameField : null,
   passwordField : null,
 
-  init : function (aHostname, aFormSubmitURL, aHttpRealm,
-                   aUsername,      aPassword,
-                   aUsernameField, aPasswordField) {
+  init : function(aHostname, aFormSubmitURL, aHttpRealm,
+                  aUsername,      aPassword,
+                  aUsernameField, aPasswordField) {
     this.hostname      = aHostname;
     this.formSubmitURL = aFormSubmitURL;
     this.httpRealm     = aHttpRealm;
     this.username      = aUsername;
     this.password      = aPassword;
     this.usernameField = aUsernameField;
     this.passwordField = aPasswordField;
   },
 
   matches(aLogin, ignorePassword) {
     return LoginHelper.doLoginsMatch(this, aLogin, {
       ignorePassword,
     });
   },
 
-  equals : function (aLogin) {
+  equals : function(aLogin) {
     if (this.hostname      != aLogin.hostname      ||
         this.formSubmitURL != aLogin.formSubmitURL ||
         this.httpRealm     != aLogin.httpRealm     ||
         this.username      != aLogin.username      ||
         this.password      != aLogin.password      ||
         this.usernameField != aLogin.usernameField ||
         this.passwordField != aLogin.passwordField)
       return false;
--- a/toolkit/components/passwordmgr/nsLoginManagerPrompter.js
+++ b/toolkit/components/passwordmgr/nsLoginManagerPrompter.js
@@ -41,31 +41,31 @@ function LoginManagerPromptFactory() {
 LoginManagerPromptFactory.prototype = {
 
   classID : Components.ID("{749e62f4-60ae-4569-a8a2-de78b649660e}"),
   QueryInterface : XPCOMUtils.generateQI([Ci.nsIPromptFactory, Ci.nsIObserver, Ci.nsISupportsWeakReference]),
 
   _asyncPrompts : {},
   _asyncPromptInProgress : false,
 
-  observe : function (subject, topic, data) {
+  observe : function(subject, topic, data) {
     this.log("Observed: " + topic);
     if (topic == "quit-application-granted") {
       this._cancelPendingPrompts();
     } else if (topic == "passwordmgr-crypto-login") {
       // Start processing the deferred prompters.
       this._doAsyncPrompt();
     } else if (topic == "passwordmgr-crypto-loginCanceled") {
       // User canceled a Master Password prompt, so go ahead and cancel
       // all pending auth prompts to avoid nagging over and over.
       this._cancelPendingPrompts();
     }
   },
 
-  getPrompt : function (aWindow, aIID) {
+  getPrompt : function(aWindow, aIID) {
     var prompt = new LoginManagerPrompter().QueryInterface(aIID);
     prompt.init(aWindow, this);
     return prompt;
   },
 
   _doAsyncPrompt : function() {
     if (this._asyncPromptInProgress) {
       this.log("_doAsyncPrompt bypassed, already in progress");
@@ -278,18 +278,18 @@ LoginManagerPrompter.prototype = {
 
   /* ---------- nsIAuthPrompt prompts ---------- */
 
 
   /**
    * Wrapper around the prompt service prompt. Saving random fields here
    * doesn't really make sense and therefore isn't implemented.
    */
-  prompt : function (aDialogTitle, aText, aPasswordRealm,
-                     aSavePassword, aDefaultText, aResult) {
+  prompt : function(aDialogTitle, aText, aPasswordRealm,
+                    aSavePassword, aDefaultText, aResult) {
     if (aSavePassword != Ci.nsIAuthPrompt.SAVE_PASSWORD_NEVER)
       throw new Components.Exception("prompt only supports SAVE_PASSWORD_NEVER",
                                      Cr.NS_ERROR_NOT_IMPLEMENTED);
 
     this.log("===== prompt() called =====");
 
     if (aDefaultText) {
       aResult.value = aDefaultText;
@@ -299,17 +299,17 @@ LoginManagerPrompter.prototype = {
            aDialogTitle, aText, aResult, null, {});
   },
 
 
   /**
    * Looks up a username and password in the database. Will prompt the user
    * with a dialog, even if a username and password are found.
    */
-  promptUsernameAndPassword : function (aDialogTitle, aText, aPasswordRealm,
+  promptUsernameAndPassword : function(aDialogTitle, aText, aPasswordRealm,
                                        aSavePassword, aUsername, aPassword) {
     this.log("===== promptUsernameAndPassword() called =====");
 
     if (aSavePassword == Ci.nsIAuthPrompt.SAVE_PASSWORD_FOR_SESSION)
       throw new Components.Exception("promptUsernameAndPassword doesn't support SAVE_PASSWORD_FOR_SESSION",
                                      Cr.NS_ERROR_NOT_IMPLEMENTED);
 
     var selectedLogin = null;
@@ -400,18 +400,18 @@ LoginManagerPrompter.prototype = {
   /**
    * If a password is found in the database for the password realm, it is
    * returned straight away without displaying a dialog.
    *
    * If a password is not found in the database, the user will be prompted
    * with a dialog with a text field and ok/cancel buttons. If the user
    * allows it, then the password will be saved in the database.
    */
-  promptPassword : function (aDialogTitle, aText, aPasswordRealm,
-                             aSavePassword, aPassword) {
+  promptPassword : function(aDialogTitle, aText, aPasswordRealm,
+                            aSavePassword, aPassword) {
     this.log("===== promptPassword called() =====");
 
     if (aSavePassword == Ci.nsIAuthPrompt.SAVE_PASSWORD_FOR_SESSION)
       throw new Components.Exception("promptPassword doesn't support SAVE_PASSWORD_FOR_SESSION",
                                      Cr.NS_ERROR_NOT_IMPLEMENTED);
 
     var checkBox = { value : false };
     var checkBoxLabel = null;
@@ -476,17 +476,17 @@ LoginManagerPrompter.prototype = {
    *   - the realm (hostname + path)
    *   - the username, if present
    *
    * If aRealmString is in the format produced by NS_GetAuthKey for HTTP[S]
    * channels, e.g. "example.com:80 (httprealm)", null is returned for all
    * arguments to let callers know the login can't be saved because we don't
    * know whether it's http or https.
    */
-  _getRealmInfo : function (aRealmString) {
+  _getRealmInfo : function(aRealmString) {
     var httpRealm = /^.+ \(.+\)$/;
     if (httpRealm.test(aRealmString))
       return [null, null, null];
 
     var uri = Services.io.newURI(aRealmString, null, null);
     var pathname = "";
 
     if (uri.path != "/")
@@ -504,17 +504,17 @@ LoginManagerPrompter.prototype = {
 
   /**
    * Implementation of nsIAuthPrompt2.
    *
    * @param {nsIChannel} aChannel
    * @param {int}        aLevel
    * @param {nsIAuthInformation} aAuthInfo
    */
-  promptAuth : function (aChannel, aLevel, aAuthInfo) {
+  promptAuth : function(aChannel, aLevel, aAuthInfo) {
     var selectedLogin = null;
     var checkbox = { value : false };
     var checkboxLabel = null;
     var epicfail = false;
     var canAutologin = false;
     var notifyObj;
     var foundLogins;
 
@@ -635,17 +635,17 @@ LoginManagerPrompter.prototype = {
     } catch (e) {
       Components.utils.reportError("LoginManagerPrompter: " +
           "Fail2 in promptAuth: " + e + "\n");
     }
 
     return ok;
   },
 
-  asyncPromptAuth : function (aChannel, aCallback, aContext, aLevel, aAuthInfo) {
+  asyncPromptAuth : function(aChannel, aCallback, aContext, aLevel, aAuthInfo) {
     var cancelable = null;
 
     try {
       this.log("===== asyncPromptAuth called =====");
 
       // If the user submits a login but it fails, we need to remove the
       // notification bar that was displayed. Conveniently, the user will
       // be prompted for authentication again, which brings us here.
@@ -688,17 +688,17 @@ LoginManagerPrompter.prototype = {
   },
 
 
 
 
   /* ---------- nsILoginManagerPrompter prompts ---------- */
 
 
-  init : function (aWindow = null, aFactory = null) {
+  init : function(aWindow = null, aFactory = null) {
     if (!aWindow) {
       // There may be no applicable window e.g. in a Sandbox or JSM.
       this._chromeWindow = null;
       this._browser = null;
     } else if (aWindow instanceof Ci.nsIDOMChromeWindow) {
       this._chromeWindow = aWindow;
       // needs to be set explicitly using setBrowser
       this._browser = null;
@@ -716,29 +716,29 @@ LoginManagerPrompter.prototype = {
   set browser(aBrowser) {
     this._browser = aBrowser;
   },
 
   set opener(aOpener) {
     this._opener = aOpener;
   },
 
-  promptToSavePassword : function (aLogin) {
+  promptToSavePassword : function(aLogin) {
     this.log("promptToSavePassword");
     var notifyObj = this._getPopupNote() || this._getNotifyBox();
     if (notifyObj)
       this._showSaveLoginNotification(notifyObj, aLogin);
     else
       this._showSaveLoginDialog(aLogin);
   },
 
   /**
    * Displays a notification bar.
    */
-  _showLoginNotification : function (aNotifyBox, aName, aText, aButtons) {
+  _showLoginNotification : function(aNotifyBox, aName, aText, aButtons) {
     var oldBar = aNotifyBox.getNotificationWithValue(aName);
     const priority = aNotifyBox.PRIORITY_INFO_MEDIUM;
 
     this.log("Adding new " + aName + " notification bar");
     var newBar = aNotifyBox.appendNotification(
                             aText, aName, "",
                             priority, aButtons);
 
@@ -956,17 +956,17 @@ LoginManagerPrompter.prototype = {
       "password-notification-icon",
       mainAction,
       secondaryActions,
       {
         timeout: Date.now() + 10000,
         displayURI: Services.io.newURI(login.hostname, null, null),
         persistWhileVisible: true,
         passwordNotificationType: type,
-        eventCallback: function (topic) {
+        eventCallback: function(topic) {
           switch (topic) {
             case "showing":
               currentNotification = this;
               chromeDoc.getElementById("password-notification-password")
                        .removeAttribute("focused");
               chromeDoc.getElementById("password-notification-username")
                        .removeAttribute("focused");
               chromeDoc.getElementById("password-notification-username")
@@ -1014,17 +1014,17 @@ LoginManagerPrompter.prototype = {
    * to save the specified login. This allows the user to see the results of
    * their login, and only save a login which they know worked.
    *
    * @param aNotifyObj
    *        A notification box or a popup notification.
    * @param aLogin
    *        The login captured from the form.
    */
-  _showSaveLoginNotification : function (aNotifyObj, aLogin) {
+  _showSaveLoginNotification : function(aNotifyObj, aLogin) {
     // Ugh. We can't use the strings from the popup window, because they
     // have the access key marked in the string (eg "Mo&zilla"), along
     // with some weird rules for handling access keys that do not occur
     // in the string, for L10N. See commonDialog.js's setLabelForNode().
     var neverButtonText =
           this._getLocalizedString("notifyBarNeverRememberButtonText");
     var neverButtonAccessKey =
           this._getLocalizedString("notifyBarNeverRememberButtonAccessKey");
@@ -1083,17 +1083,17 @@ LoginManagerPrompter.prototype = {
 
       this._showLoginNotification(aNotifyObj, "password-save",
                                   notificationText, buttons);
     }
 
     Services.obs.notifyObservers(aLogin, "passwordmgr-prompt-save", null);
   },
 
-  _removeLoginNotifications : function () {
+  _removeLoginNotifications : function() {
     var popupNote = this._getPopupNote();
     if (popupNote)
       popupNote = popupNote.getNotification("password");
     if (popupNote)
       popupNote.remove();
 
     var notifyBox = this._getNotifyBox();
     if (notifyBox) {
@@ -1111,17 +1111,17 @@ LoginManagerPrompter.prototype = {
     }
   },
 
 
   /**
    * Called when we detect a new login in a form submission,
    * asks the user what to do.
    */
-  _showSaveLoginDialog : function (aLogin) {
+  _showSaveLoginDialog : function(aLogin) {
     const buttonFlags = Ci.nsIPrompt.BUTTON_POS_1_DEFAULT +
         (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_0) +
         (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_1) +
         (Ci.nsIPrompt.BUTTON_TITLE_IS_STRING * Ci.nsIPrompt.BUTTON_POS_2);
 
     var displayHost = this._getShortDisplayHost(aLogin.hostname);
 
     var dialogText;
@@ -1303,17 +1303,17 @@ LoginManagerPrompter.prototype = {
    * to select a username and confirm the password change.
    *
    * Note: The caller doesn't know the username for aNewLogin, so this
    *       function fills in .username and .usernameField with the values
    *       from the login selected by the user.
    *
    * Note; XPCOM stupidity: |count| is just |logins.length|.
    */
-  promptToChangePasswordWithUsernames : function (logins, count, aNewLogin) {
+  promptToChangePasswordWithUsernames : function(logins, count, aNewLogin) {
     this.log("promptToChangePasswordWithUsernames with count:", count);
 
     var usernames = logins.map(l => l.username);
     var dialogText  = this._getLocalizedString("userSelectText");
     var dialogTitle = this._getLocalizedString("passwordChangeTitle");
     var selectedIndex = { value: null };
 
     // If user selects ok, outparam.value is set to the index
@@ -1361,29 +1361,29 @@ LoginManagerPrompter.prototype = {
     propBag.setProperty("timeLastUsed", now);
     propBag.setProperty("timesUsedIncrement", 1);
     this._pwmgr.modifyLogin(login, propBag);
   },
 
   /**
    * Given a content DOM window, returns the chrome window and browser it's in.
    */
-  _getChromeWindow: function (aWindow) {
+  _getChromeWindow: function(aWindow) {
     let windows = Services.wm.getEnumerator(null);
     while (windows.hasMoreElements()) {
       let win = windows.getNext();
       let browser = win.gBrowser.getBrowserForContentWindow(aWindow);
       if (browser) {
         return { win, browser };
       }
     }
     return null;
   },
 
-  _getNotifyWindow: function () {
+  _getNotifyWindow: function() {
     // Some sites pop up a temporary login window, which disappears
     // upon submission of credentials. We want to put the notification
     // bar in the opener window if this seems to be happening.
     if (this._opener) {
       let chromeDoc = this._chromeWindow.document.documentElement;
 
       // Check to see if the current window was opened with chrome
       // disabled, and if so use the opener window. But if the window
@@ -1397,17 +1397,17 @@ LoginManagerPrompter.prototype = {
 
     return { win: this._chromeWindow, browser: this._browser };
   },
 
   /**
    * Returns the popup notification to this prompter,
    * or null if there isn't one available.
    */
-  _getPopupNote : function () {
+  _getPopupNote : function() {
     let popupNote = null;
 
     try {
       let { win: notifyWin } = this._getNotifyWindow();
 
       // .wrappedJSObject needed here -- see bug 422974 comment 5.
       popupNote = notifyWin.wrappedJSObject.PopupNotifications;
     } catch (e) {
@@ -1417,17 +1417,17 @@ LoginManagerPrompter.prototype = {
     return popupNote;
   },
 
 
   /**
    * Returns the notification box to this prompter, or null if there isn't
    * a notification box available.
    */
-  _getNotifyBox : function () {
+  _getNotifyBox : function() {
     let notifyBox = null;
 
     try {
       let { win: notifyWin } = this._getNotifyWindow();
 
       // .wrappedJSObject needed here -- see bug 422974 comment 5.
       notifyBox = notifyWin.wrappedJSObject.getNotificationBox(notifyWin);
     } catch (e) {
@@ -1438,17 +1438,17 @@ LoginManagerPrompter.prototype = {
   },
 
 
   /**
    * The user might enter a login that isn't the one we prefilled, but
    * is the same as some other existing login. So, pick a login with a
    * matching username, or return null.
    */
-  _repickSelectedLogin : function (foundLogins, username) {
+  _repickSelectedLogin : function(foundLogins, username) {
     for (var i = 0; i < foundLogins.length; i++)
       if (foundLogins[i].username == username)
         return foundLogins[i];
     return null;
   },
 
 
   /**
@@ -1457,62 +1457,62 @@ LoginManagerPrompter.prototype = {
    *   _getLocalizedString("key2", ["arg1"]);
    *   _getLocalizedString("key3", ["arg1", "arg2"]);
    *   (etc)
    *
    * Returns the localized string for the specified key,
    * formatted if required.
    *
    */
-  _getLocalizedString : function (key, formatArgs) {
+  _getLocalizedString : function(key, formatArgs) {
     if (formatArgs)
       return this._strBundle.formatStringFromName(
                                   key, formatArgs, formatArgs.length);
     return this._strBundle.GetStringFromName(key);
   },
 
 
   /**
    * Sanitizes the specified username, by stripping quotes and truncating if
    * it's too long. This helps prevent an evil site from messing with the
    * "save password?" prompt too much.
    */
-  _sanitizeUsername : function (username) {
+  _sanitizeUsername : function(username) {
     if (username.length > 30) {
       username = username.substring(0, 30);
       username += this._ellipsis;
     }
     return username.replace(/['"]/g, "");
   },
 
 
   /**
    * The aURI parameter may either be a string uri, or an nsIURI instance.
    *
    * Returns the hostname to use in a nsILoginInfo object (for example,
    * "http://example.com").
    */
-  _getFormattedHostname : function (aURI) {
+  _getFormattedHostname : function(aURI) {
     let uri;
     if (aURI instanceof Ci.nsIURI) {
       uri = aURI;
     } else {
       uri = Services.io.newURI(aURI, null, null);
     }
 
     return uri.scheme + "://" + uri.hostPort;
   },
 
 
   /**
    * Converts a login's hostname field (a URL) to a short string for
    * prompting purposes. Eg, "http://foo.com" --> "foo.com", or
    * "ftp://www.site.co.uk" --> "site.co.uk".
    */
-  _getShortDisplayHost: function (aURIString) {
+  _getShortDisplayHost: function(aURIString) {
     var displayHost;
 
     var eTLDService = Cc["@mozilla.org/network/effective-tld-service;1"].
                       getService(Ci.nsIEffectiveTLDService);
     var idnService = Cc["@mozilla.org/network/idn-service;1"].
                      getService(Ci.nsIIDNService);
     try {
       var uri = Services.io.newURI(aURIString, null, null);
@@ -1528,17 +1528,17 @@ LoginManagerPrompter.prototype = {
     return displayHost;
   },
 
 
   /**
    * Returns the hostname and realm for which authentication is being
    * requested, in the format expected to be used with nsILoginInfo.
    */
-  _getAuthTarget : function (aChannel, aAuthInfo) {
+  _getAuthTarget : function(aChannel, aAuthInfo) {
     var hostname, realm;
 
     // If our proxy is demanding authentication, don't use the
     // channel's actual destination.
     if (aAuthInfo.flags & Ci.nsIAuthInformation.AUTH_PROXY) {
       this.log("getAuthTarget is for proxy auth");
       if (!(aChannel instanceof Ci.nsIProxiedChannel))
         throw new Error("proxy auth needs nsIProxiedChannel");
@@ -1576,17 +1576,17 @@ LoginManagerPrompter.prototype = {
 
   /**
    * Returns [username, password] as extracted from aAuthInfo (which
    * holds this info after having prompted the user).
    *
    * If the authentication was for a Windows domain, we'll prepend the
    * return username with the domain. (eg, "domain\user")
    */
-  _GetAuthInfo : function (aAuthInfo) {
+  _GetAuthInfo : function(aAuthInfo) {
     var username, password;
 
     var flags = aAuthInfo.flags;
     if (flags & Ci.nsIAuthInformation.NEED_DOMAIN && aAuthInfo.domain)
       username = aAuthInfo.domain + "\\" + aAuthInfo.username;
     else
       username = aAuthInfo.username;
 
@@ -1596,17 +1596,17 @@ LoginManagerPrompter.prototype = {
   },
 
 
   /**
    * Given a username (possibly in DOMAIN\user form) and password, parses the
    * domain out of the username if necessary and sets domain, username and
    * password on the auth information object.
    */
-  _SetAuthInfo : function (aAuthInfo, username, password) {
+  _SetAuthInfo : function(aAuthInfo, username, password) {
     var flags = aAuthInfo.flags;
     if (flags & Ci.nsIAuthInformation.NEED_DOMAIN) {
       // Domain is separated from username by a backslash
       var idx = username.indexOf("\\");
       if (idx == -1) {
         aAuthInfo.username = username;
       } else {
         aAuthInfo.domain   =  username.substring(0, idx);
--- a/toolkit/components/passwordmgr/storage-json.js
+++ b/toolkit/components/passwordmgr/storage-json.js
@@ -22,17 +22,17 @@ XPCOMUtils.defineLazyModuleGetter(this, 
                                   "resource://gre/modules/LoginStore.jsm");
 XPCOMUtils.defineLazyModuleGetter(this, "OS",
                                   "resource://gre/modules/osfile.jsm");
 
 XPCOMUtils.defineLazyServiceGetter(this, "gUUIDGenerator",
                                    "@mozilla.org/uuid-generator;1",
                                    "nsIUUIDGenerator");
 
-this.LoginManagerStorage_json = function () {};
+this.LoginManagerStorage_json = function() {};
 
 this.LoginManagerStorage_json.prototype = {
   classID: Components.ID("{c00c432d-a0c9-46d7-bef6-9c45b4d07341}"),
   QueryInterface: XPCOMUtils.generateQI([Ci.nsILoginManagerStorage]),
 
   __crypto: null,  // nsILoginManagerCrypto service
   get _crypto() {
     if (!this.__crypto)
--- a/toolkit/components/passwordmgr/storage-mozStorage.js
+++ b/toolkit/components/passwordmgr/storage-mozStorage.js
@@ -158,17 +158,17 @@ LoginManagerStorage_mozStorage.prototype
   initWithFile : function(aDBFile) {
     if (aDBFile)
       this._signonsFile = aDBFile;
 
     this.initialize();
   },
 
 
-  initialize : function () {
+  initialize : function() {
     this._dbStmts = {};
 
     let isFirstRun;
     try {
       // Force initialization of the crypto module.
       // See bug 717490 comment 17.
       this._crypto;
 
@@ -195,22 +195,22 @@ LoginManagerStorage_mozStorage.prototype
     }
   },
 
 
   /**
    * Internal method used by regression tests only.  It is called before
    * replacing this storage module with a new instance.
    */
-  terminate : function () {
+  terminate : function() {
     return Promise.resolve();
   },
 
 
-  addLogin : function (login) {
+  addLogin : function(login) {
     // Throws if there are bogus values.
     LoginHelper.checkLoginValues(login);
 
     let [encUsername, encPassword, encType] = this._encryptLogin(login);
 
     // Clone the login, so we don't modify the caller's object.
     let loginClone = login.clone();
 
@@ -274,17 +274,17 @@ LoginManagerStorage_mozStorage.prototype
       }
     }
 
     // Send a notification that a login was added.
     LoginHelper.notifyStorageChanged("addLogin", loginClone);
   },
 
 
-  removeLogin : function (login) {
+  removeLogin : function(login) {
     let [idToDelete, storedLogin] = this._getIdForLogin(login);
     if (!idToDelete)
       throw new Error("No matching logins");
 
     // Execute the statement & remove from DB
     let query  = "DELETE FROM moz_logins WHERE id = :id";
     let params = { id: idToDelete };
     let stmt;
@@ -301,17 +301,17 @@ LoginManagerStorage_mozStorage.prototype
     } finally {
       if (stmt) {
         stmt.reset();
       }
     }
     LoginHelper.notifyStorageChanged("removeLogin", storedLogin);
   },
 
-  modifyLogin : function (oldLogin, newLoginData) {
+  modifyLogin : function(oldLogin, newLoginData) {
     let [idToModify, oldStoredLogin] = this._getIdForLogin(oldLogin);
     if (!idToModify)
       throw new Error("No matching logins");
 
     let newLogin = LoginHelper.buildModifiedLogin(oldStoredLogin, newLoginData);
 
     // Check if the new GUID is duplicate.
     if (newLogin.guid != oldStoredLogin.guid &&
@@ -381,17 +381,17 @@ LoginManagerStorage_mozStorage.prototype
 
     LoginHelper.notifyStorageChanged("modifyLogin", [oldStoredLogin, newLogin]);
   },
 
 
   /**
    * Returns an array of nsILoginInfo.
    */
-  getAllLogins : function (count) {
+  getAllLogins : function(count) {
     let [logins, ids] = this._searchLogins({});
 
     // decrypt entries for caller.
     logins = this._decryptLogins(logins);
 
     this.log("_getAllLogins: returning " + logins.length + " logins.");
     if (count)
       count.value = logins.length; // needed for XPCOM
@@ -438,17 +438,17 @@ LoginManagerStorage_mozStorage.prototype
   /**
    * Private method to perform arbitrary searches on any field. Decryption is
    * left to the caller.
    *
    * Returns [logins, ids] for logins that match the arguments, where logins
    * is an array of encrypted nsLoginInfo and ids is an array of associated
    * ids in the database.
    */
-  _searchLogins : function (matchData, aOptions = {
+  _searchLogins : function(matchData, aOptions = {
     schemeUpgrades: false,
   }) {
     let conditions = [], params = {};
 
     for (let field in matchData) {
       let value = matchData[field];
       let condition = "";
       switch (field) {
@@ -566,17 +566,17 @@ LoginManagerStorage_mozStorage.prototype
         stmt.reset();
     }
   },
 
 
   /**
    * Removes all logins from storage.
    */
-  removeAllLogins : function () {
+  removeAllLogins : function() {
     this.log("Removing all logins");
     let query;
     let stmt;
     let transaction = new Transaction(this._dbConnection);
 
     // Disabled hosts kept, as one presumably doesn't want to erase those.
     // TODO: Add these items to the deleted items table once we've sorted
     //       out the issues from bug 756701
@@ -594,17 +594,17 @@ LoginManagerStorage_mozStorage.prototype
         stmt.reset();
       }
     }
 
     LoginHelper.notifyStorageChanged("removeAllLogins", null);
   },
 
 
-  findLogins : function (count, hostname, formSubmitURL, httpRealm) {
+  findLogins : function(count, hostname, formSubmitURL, httpRealm) {
     let loginData = {
       hostname: hostname,
       formSubmitURL: formSubmitURL,
       httpRealm: httpRealm
     };
     let matchData = { };
     for (let field of ["hostname", "formSubmitURL", "httpRealm"])
       if (loginData[field] != '')
@@ -615,17 +615,17 @@ LoginManagerStorage_mozStorage.prototype
     logins = this._decryptLogins(logins);
 
     this.log("_findLogins: returning " + logins.length + " logins");
     count.value = logins.length; // needed for XPCOM
     return logins;
   },
 
 
-  countLogins : function (hostname, formSubmitURL, httpRealm) {
+  countLogins : function(hostname, formSubmitURL, httpRealm) {
 
     let _countLoginsHelper = (hostname, formSubmitURL, httpRealm) => {
       // Do checks for null and empty strings, adjust conditions and params
       let [conditions, params] =
           this._buildConditionsAndParams(hostname, formSubmitURL, httpRealm);
 
       let query = "SELECT COUNT(1) AS numLogins FROM moz_logins";
       if (conditions.length) {
@@ -664,17 +664,17 @@ LoginManagerStorage_mozStorage.prototype
   },
 
 
   /**
    * Returns an array with two items: [id, login]. If the login was not
    * found, both items will be null. The returned login contains the actual
    * stored login (useful for looking at the actual nsILoginMetaInfo values).
    */
-  _getIdForLogin : function (login) {
+  _getIdForLogin : function(login) {
     let matchData = { };
     for (let field of ["hostname", "formSubmitURL", "httpRealm"])
       if (login[field] != '')
         matchData[field] = login[field];
     let [logins, ids] = this._searchLogins(matchData);
 
     let id = null;
     let foundLogin = null;
@@ -699,17 +699,17 @@ LoginManagerStorage_mozStorage.prototype
   },
 
 
   /**
    * Adjusts the WHERE conditions and parameters for statements prior to the
    * statement being created. This fixes the cases where nulls are involved
    * and the empty string is supposed to be a wildcard match
    */
-  _buildConditionsAndParams : function (hostname, formSubmitURL, httpRealm) {
+  _buildConditionsAndParams : function(hostname, formSubmitURL, httpRealm) {
     let conditions = [], params = {};
 
     if (hostname == null) {
       conditions.push("hostname isnull");
     } else if (hostname != '') {
       conditions.push("hostname = :hostname");
       params["hostname"] = hostname;
     }
@@ -730,17 +730,17 @@ LoginManagerStorage_mozStorage.prototype
 
     return [conditions, params];
   },
 
 
   /**
    * Checks to see if the specified GUID already exists.
    */
-  _isGuidUnique : function (guid) {
+  _isGuidUnique : function(guid) {
     let query = "SELECT COUNT(1) AS numLogins FROM moz_logins WHERE guid = :guid";
     let params = { guid: guid };
 
     let stmt, numLogins;
     try {
       stmt = this._dbCreateStatement(query, params);
       stmt.executeStep();
       numLogins = stmt.row.numLogins;
@@ -755,17 +755,17 @@ LoginManagerStorage_mozStorage.prototype
     return (numLogins == 0);
   },
 
 
   /**
    * Returns the encrypted username, password, and encrypton type for the specified
    * login. Can throw if the user cancels a master password entry.
    */
-  _encryptLogin : function (login) {
+  _encryptLogin : function(login) {
     let encUsername = this._crypto.encrypt(login.username);
     let encPassword = this._crypto.encrypt(login.password);
     let encType     = this._crypto.defaultEncType;
 
     return [encUsername, encPassword, encType];
   },
 
 
@@ -775,17 +775,17 @@ LoginManagerStorage_mozStorage.prototype
    *
    * The entries specified by the array will be decrypted, if possible.
    * An array of successfully decrypted logins will be returned. The return
    * value should be given to external callers (since still-encrypted
    * entries are useless), whereas internal callers generally don't want
    * to lose unencrypted entries (eg, because the user clicked Cancel
    * instead of entering their master password)
    */
-  _decryptLogins : function (logins) {
+  _decryptLogins : function(logins) {
     let result = [];
 
     for (let login of logins) {
       try {
         login.username = this._crypto.decrypt(login.username);
         login.password = this._crypto.decrypt(login.password);
       } catch (e) {
         // If decryption failed (corrupt entry?), just skip it.
@@ -803,17 +803,17 @@ LoginManagerStorage_mozStorage.prototype
 
   // Database Creation & Access
 
   /**
    * Creates a statement, wraps it, and then does parameter replacement
    * Returns the wrapped statement for execution.  Will use memoization
    * so that statements can be reused.
    */
-  _dbCreateStatement : function (query, params) {
+  _dbCreateStatement : function(query, params) {
     let wrappedStmt = this._dbStmts[query];
     // Memoize the statements
     if (!wrappedStmt) {
       this.log("Creating new statement for query: " + query);
       wrappedStmt = this._dbConnection.createStatement(query);
       this._dbStmts[query] = wrappedStmt;
     }
     // Replace parameters, must be done 1 at a time
@@ -823,17 +823,17 @@ LoginManagerStorage_mozStorage.prototype
     return wrappedStmt;
   },
 
 
   /**
    * Attempts to initialize the database. This creates the file if it doesn't
    * exist, performs any migrations, etc. Return if this is the first run.
    */
-  _dbInit : function () {
+  _dbInit : function() {
     this.log("Initializing Database");
     let isFirstRun = false;
     try {
       this._dbConnection = this._storageService.openDatabase(this._signonsFile);
       // Get the version of the schema in the file. It will be 0 if the
       // database has not been created yet.
       let version = this._dbConnection.schemaVersion;
       if (version == 0) {
@@ -850,57 +850,57 @@ LoginManagerStorage_mozStorage.prototype
       }
       throw e;
     }
 
     Services.obs.addObserver(this, "profile-before-change", false);
     return isFirstRun;
   },
 
-  observe: function (subject, topic, data) {
+  observe: function(subject, topic, data) {
     switch (topic) {
       case "profile-before-change":
         Services.obs.removeObserver(this, "profile-before-change");
         this._dbClose();
       break;
     }
   },
 
-  _dbCreate: function () {
+  _dbCreate: function() {
     this.log("Creating Database");
     this._dbCreateSchema();
     this._dbConnection.schemaVersion = DB_VERSION;
   },
 
 
-  _dbCreateSchema : function () {
+  _dbCreateSchema : function() {
     this._dbCreateTables();
     this._dbCreateIndices();
   },
 
 
-  _dbCreateTables : function () {
+  _dbCreateTables : function() {
     this.log("Creating Tables");
     for (let name in this._dbSchema.tables)
       this._dbConnection.createTable(name, this._dbSchema.tables[name]);
   },
 
 
-  _dbCreateIndices : function () {
+  _dbCreateIndices : function() {
     this.log("Creating Indices");
     for (let name in this._dbSchema.indices) {
       let index = this._dbSchema.indices[name];
       let statement = "CREATE INDEX IF NOT EXISTS " + name + " ON " + index.table +
                       "(" + index.columns.join(", ") + ")";
       this._dbConnection.executeSimpleSQL(statement);
     }
   },
 
 
-  _dbMigrate : function (oldVersion) {
+  _dbMigrate : function(oldVersion) {
     this.log("Attempting to migrate from version " + oldVersion);
 
     if (oldVersion > DB_VERSION) {
       this.log("Downgrading to version " + DB_VERSION);
       // User's DB is newer. Sanity check that our expected columns are
       // present, and if so mark the lower version and merrily continue
       // on. If the columns are borked, something is wrong so blow away
       // the DB and start from scratch. [Future incompatible upgrades
@@ -937,17 +937,17 @@ LoginManagerStorage_mozStorage.prototype
     transaction.commit();
     this.log("DB migration completed.");
   },
 
 
   /**
    * Version 2 adds a GUID column. Existing logins are assigned a random GUID.
    */
-  _dbMigrateToVersion2 : function () {
+  _dbMigrateToVersion2 : function() {
     // Check to see if GUID column already exists, add if needed
     let query;
     if (!this._dbColumnExists("guid")) {
       query = "ALTER TABLE moz_logins ADD COLUMN guid TEXT";
       this._dbConnection.executeSimpleSQL(query);
 
       query = "CREATE INDEX IF NOT EXISTS moz_logins_guid_index ON moz_logins (guid)";
       this._dbConnection.executeSimpleSQL(query);
@@ -991,17 +991,17 @@ LoginManagerStorage_mozStorage.prototype
       }
     }
   },
 
 
   /**
    * Version 3 adds a encType column.
    */
-  _dbMigrateToVersion3 : function () {
+  _dbMigrateToVersion3 : function() {
     // Check to see if encType column already exists, add if needed
     let query;
     if (!this._dbColumnExists("encType")) {
       query = "ALTER TABLE moz_logins ADD COLUMN encType INTEGER";
       this._dbConnection.executeSimpleSQL(query);
 
       query = "CREATE INDEX IF NOT EXISTS " +
                   "moz_logins_encType_index ON moz_logins (encType)";
@@ -1051,17 +1051,17 @@ LoginManagerStorage_mozStorage.prototype
     }
   },
 
 
   /**
    * Version 4 adds timeCreated, timeLastUsed, timePasswordChanged,
    * and timesUsed columns
    */
-  _dbMigrateToVersion4 : function () {
+  _dbMigrateToVersion4 : function() {
     let query;
     // Add the new columns, if needed.
     for (let column of ["timeCreated", "timeLastUsed", "timePasswordChanged", "timesUsed"]) {
       if (!this._dbColumnExists(column)) {
         query = "ALTER TABLE moz_logins ADD COLUMN " + column + " INTEGER";
         this._dbConnection.executeSimpleSQL(query);
       }
     }
@@ -1106,27 +1106,27 @@ LoginManagerStorage_mozStorage.prototype
       }
     }
   },
 
 
   /**
    * Version 5 adds the moz_deleted_logins table
    */
-  _dbMigrateToVersion5 : function () {
+  _dbMigrateToVersion5 : function() {
     if (!this._dbConnection.tableExists("moz_deleted_logins")) {
       this._dbConnection.createTable("moz_deleted_logins", this._dbSchema.tables.moz_deleted_logins);
     }
   },
 
   /**
    * Version 6 migrates all the hosts from
    * moz_disabledHosts to the permission manager.
    */
-  _dbMigrateToVersion6 : function () {
+  _dbMigrateToVersion6 : function() {
     let disabledHosts = [];
     let query = "SELECT hostname FROM moz_disabledHosts";
     let stmt;
 
     try {
       stmt = this._dbCreateStatement(query);
 
       while (stmt.executeStep()) {
@@ -1152,17 +1152,17 @@ LoginManagerStorage_mozStorage.prototype
     query = "DELETE FROM moz_disabledHosts";
     this._dbConnection.executeSimpleSQL(query);
   },
 
   /**
    * Sanity check to ensure that the columns this version of the code expects
    * are present in the DB we're using.
    */
-  _dbAreExpectedColumnsPresent : function () {
+  _dbAreExpectedColumnsPresent : function() {
     let query = "SELECT " +
                    "id, " +
                    "hostname, " +
                    "httpRealm, " +
                    "formSubmitURL, " +
                    "usernameField, " +
                    "passwordField, " +
                    "encryptedUsername, " +
@@ -1197,29 +1197,29 @@ LoginManagerStorage_mozStorage.prototype
     this.log("verified that expected columns are present in DB.");
     return true;
   },
 
 
   /**
    * Checks to see if the named column already exists.
    */
-  _dbColumnExists : function (columnName) {
+  _dbColumnExists : function(columnName) {
     let query = "SELECT " + columnName + " FROM moz_logins";
     try {
       let stmt = this._dbConnection.createStatement(query);
       // (no need to execute statement, if it compiled we're good)
       stmt.finalize();
       return true;
     } catch (e) {
       return false;
     }
   },
 
-  _dbClose : function () {
+  _dbClose : function() {
     this.log("Closing the DB connection.");
     // Finalize all statements to free memory, avoid errors later
     for (let query in this._dbStmts) {
       let stmt = this._dbStmts[query];
       stmt.finalize();
     }
     this._dbStmts = {};
 
@@ -1232,17 +1232,17 @@ LoginManagerStorage_mozStorage.prototype
     }
     this._dbConnection = null;
   },
 
   /**
    * Called when database creation fails. Finalizes database statements,
    * closes the database connection, deletes the database file.
    */
-  _dbCleanup : function (backup) {
+  _dbCleanup : function(backup) {
     this.log("Cleaning up DB file - close & remove & backup=" + backup);
 
     // Create backup file
     if (backup) {
       let backupFile = this._signonsFile.leafName + ".corrupt";
       this._storageService.backupDatabaseFile(this._signonsFile, backupFile);
     }
 
--- a/toolkit/components/passwordmgr/test/browser/browser_hasInsecureLoginForms_streamConverter.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_hasInsecureLoginForms_streamConverter.js
@@ -53,17 +53,17 @@ function* registerConverter() {
     // nsIStreamListener
     onDataAvailable() {},
   };
 
   let factory = XPCOMUtils._getFactory(TestStreamConverter);
   let registrar = Components.manager.QueryInterface(Ci.nsIComponentRegistrar);
   registrar.registerFactory(TestStreamConverter.prototype.classID, "",
                             TestStreamConverter.prototype.contractID, factory);
-  this.cleanupFunction = function () {
+  this.cleanupFunction = function() {
     registrar.unregisterFactory(TestStreamConverter.prototype.classID, factory);
   };
 }
 
 /**
  * Waits for the given number of occurrences of InsecureLoginFormsStateChange
  * on the given browser element.
  */
--- a/toolkit/components/passwordmgr/test/browser/browser_insecurePasswordWarning.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_insecurePasswordWarning.js
@@ -55,17 +55,17 @@ add_task(function* testInsecurePasswordW
 
     // For a form with a secure (https) customized action link.
     ["http://127.0.0.1", "form_cross_origin_secure_action.html", []],
     ["http://example.com", "form_cross_origin_secure_action.html", ["INSECURE_PAGE"]],
     ["https://example.com", "form_cross_origin_secure_action.html", []],
   ]) {
     let testURL = origin + TEST_URL_PATH + testFile;
     let promiseConsoleMessages = new Promise(resolve => {
-      warningPatternHandler = function (warning, originMessage) {
+      warningPatternHandler = function(warning, originMessage) {
         ok(warning, "Handling a warning pattern");
         let fullMessage = `[${warning.msg} {file: "${testURL}" line: 0 column: 0 source: "0"}]`;
         is(originMessage, fullMessage, "Message full matched:" + originMessage);
 
         let index = expectWarnings.indexOf(warning.key);
         isnot(index, -1, "Found warning: " + warning.key + " for URL:" + testURL);
         if (index !== -1) {
           // Remove the shown message.
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_contextmenu.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_contextmenu.js
@@ -71,17 +71,17 @@ add_task(function* test() {
         function assertMenuitemEnabled(idSuffix, expected, reason = "") {
             doc.defaultView.UpdateContextMenu();
             let actual = !doc.getElementById("context-" + idSuffix).getAttribute("disabled");
             is(actual, expected, idSuffix + " should be " + (expected ? "enabled" : "disabled") +
                (reason ? ": " + reason : ""));
         }
 
         function cleanUp() {
-            Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+            Services.ww.registerNotification(function(aSubject, aTopic, aData) {
                 Services.ww.unregisterNotification(arguments.callee);
                 Services.logins.removeAllLogins();
                 doc.getElementById("passwordCol").hidden = true;
                 resolve();
             });
             pwmgrdlg.close();
         }
 
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_editing.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_editing.js
@@ -83,17 +83,17 @@ add_task(function* test_setup() {
   registerCleanupFunction(function() {
     Services.logins.removeAllLogins();
   });
 
   Services.logins.removeAllLogins();
   // Open the password manager dialog.
   pwmgrdlg = window.openDialog(PWMGR_DLG, "Toolkit:PasswordManager", "");
 
-  Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+  Services.ww.registerNotification(function(aSubject, aTopic, aData) {
     if (aTopic == "domwindowopened") {
       let win = aSubject.QueryInterface(Ci.nsIDOMEventTarget);
       SimpleTest.waitForFocus(function() {
         EventUtils.sendKey("RETURN", win);
       }, win);
     } else if (aSubject.location == pwmgrdlg.location && aTopic == "domwindowclosed") {
       // Unregister ourself.
       Services.ww.unregisterNotification(arguments.callee);
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_fields.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_fields.js
@@ -44,17 +44,17 @@ add_task(function* test() {
     is(timeLastUsedCol.getAttribute("hidden"), "true",
        "Last Used column is not displayed");
 
     let timePasswordChangedCol = doc.getElementById("timePasswordChangedCol");
     is(timePasswordChangedCol.getAttribute("hidden"), "",
        "Last Changed column is displayed");
 
     // cleanup
-    Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+    Services.ww.registerNotification(function(aSubject, aTopic, aData) {
       if (aSubject.location == pwmgrdlg.location && aTopic == "domwindowclosed") {
         // unregister ourself
         Services.ww.unregisterNotification(arguments.callee);
 
         pwmgr.removeAllLogins();
 
         resolve();
       }
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_observers.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_observers.js
@@ -14,17 +14,17 @@ add_task(function* test() {
     "Toolkit:PasswordManager", "");
 
   let logins = [];
   let loginCounter = 0;
   let loginOrder = null;
   let modifiedLogin;
   let testNumber = 0;
   let testObserver = {
-    observe: function (subject, topic, data) {
+    observe: function(subject, topic, data) {
       if (topic == "passwordmgr-dialog-updated") {
         switch (testNumber) {
           case 1:
           case 2:
           case 3:
           case 4:
           case 5:
             is(countLogins(), loginCounter, "Verify login added");
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_sort.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgr_sort.js
@@ -69,29 +69,29 @@ add_task(function* test() {
 
         let toggleCalls = 0;
         function toggleShowPasswords(func) {
             let toggleButton = doc.getElementById("togglePasswords");
             let showMode = (toggleCalls++ % 2) == 0;
 
             // only watch for a confirmation dialog every other time being called
             if (showMode) {
-                Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+                Services.ww.registerNotification(function(aSubject, aTopic, aData) {
                     if (aTopic == "domwindowclosed")
                         Services.ww.unregisterNotification(arguments.callee);
                     else if (aTopic == "domwindowopened") {
                         let targetWin = aSubject.QueryInterface(Ci.nsIDOMEventTarget);
                         SimpleTest.waitForFocus(function() {
                             EventUtils.sendKey("RETURN", targetWin);
                         }, targetWin);
                     }
                 });
             }
 
-            Services.obs.addObserver(function (aSubject, aTopic, aData) {
+            Services.obs.addObserver(function(aSubject, aTopic, aData) {
                 if (aTopic == "passwordmgr-password-toggle-complete") {
                     Services.obs.removeObserver(arguments.callee, aTopic);
                     func();
                 }
             }, "passwordmgr-password-toggle-complete", false);
 
             EventUtils.synthesizeMouse(toggleButton, 1, 1, {}, win);
         }
@@ -186,17 +186,17 @@ add_task(function* test() {
                 // Reset filter
                 setFilter("");
                 break;
             case 5:
                 expectedValues = pwds.slice().sort();
                 checkColumnEntries(2, expectedValues);
                 checkSortDirection(passwordCol, true);
                 // cleanup
-                Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+                Services.ww.registerNotification(function(aSubject, aTopic, aData) {
                     // unregister ourself
                     Services.ww.unregisterNotification(arguments.callee);
 
                     pwmgr.removeAllLogins();
                     resolve();
                 });
                 pwmgrdlg.close();
             }
--- a/toolkit/components/passwordmgr/test/browser/browser_passwordmgrdlg.js
+++ b/toolkit/components/passwordmgr/test/browser/browser_passwordmgrdlg.js
@@ -80,29 +80,29 @@ add_task(function* test() {
 
         let toggleCalls = 0;
         function toggleShowPasswords(func) {
             let toggleButton = doc.getElementById("togglePasswords");
             let showMode = (toggleCalls++ % 2) == 0;
 
             // only watch for a confirmation dialog every other time being called
             if (showMode) {
-                Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+                Services.ww.registerNotification(function(aSubject, aTopic, aData) {
                     if (aTopic == "domwindowclosed")
                         Services.ww.unregisterNotification(arguments.callee);
                     else if (aTopic == "domwindowopened") {
                         let targetWin = aSubject.QueryInterface(Ci.nsIDOMEventTarget);
                         SimpleTest.waitForFocus(function() {
                             EventUtils.sendKey("RETURN", targetWin);
                         }, targetWin);
                     }
                 });
             }
 
-            Services.obs.addObserver(function (aSubject, aTopic, aData) {
+            Services.obs.addObserver(function(aSubject, aTopic, aData) {
                 if (aTopic == "passwordmgr-password-toggle-complete") {
                     Services.obs.removeObserver(arguments.callee, aTopic);
                     func();
                 }
             }, "passwordmgr-password-toggle-complete", false);
 
             EventUtils.synthesizeMouse(toggleButton, 1, 1, {}, win);
         }
@@ -126,17 +126,17 @@ add_task(function* test() {
                     expected = testCase.count;
                     break;
                 case 2: // showing passwords
                     expected = ("count2" in testCase) ? testCase.count2 : testCase.count;
                     break;
                 case 3: // toggle
                     expected = testCase.count;
                     tester();
-                    toggleShowPasswords(function () {
+                    toggleShowPasswords(function() {
                         expected = ("count2" in testCase) ? testCase.count2 : testCase.count;
                         tester();
                         toggleShowPasswords(proceed);
                     });
                     return;
                 }
                 tester();
                 proceed();
@@ -172,17 +172,17 @@ add_task(function* test() {
         function step3() {
             toggleShowPasswords(function() {
                 runTests(3, lastStep);
             });
         }
 
         function lastStep() {
             // cleanup
-            Services.ww.registerNotification(function (aSubject, aTopic, aData) {
+            Services.ww.registerNotification(function(aSubject, aTopic, aData) {
                 // unregister ourself
                 Services.ww.unregisterNotification(arguments.callee);
 
                 pwmgr.removeAllLogins();
                 finish();
             });
             pwmgrdlg.close();
         }
--- a/toolkit/components/passwordmgr/test/browser/formless_basic.html
+++ b/toolkit/components/passwordmgr/test/browser/formless_basic.html
@@ -3,16 +3,16 @@
 <!-- Simplest form with username and password fields. -->
   <input id="form-basic-username" name="username">
   <input id="form-basic-password" name="password" type="password">
   <input id="form-basic-submit" type="submit">
 
   <button id="add">Add input[type=password]</button>
 
   <script>
-    document.getElementById("add").addEventListener("click", function () {
+    document.getElementById("add").addEventListener("click", function() {
       var node = document.createElement("input");
       node.setAttribute("type", "password");
       document.querySelector("body").appendChild(node);
     });
   </script>
 
 </body></html>
--- a/toolkit/components/passwordmgr/test/mochitest/test_prompt_promptAuth_proxy.html
+++ b/toolkit/components/passwordmgr/test/mochitest/test_prompt_promptAuth_proxy.html
@@ -78,25 +78,25 @@ function proxyChannelListener() { }
 proxyChannelListener.prototype = {
   onStartRequest: function(request, context) {
     startupCompleteResolver();
   },
   onStopRequest: function(request, context, status) { }
 };
 
 var resolveCallback = SpecialPowers.wrapCallbackObject({
-  QueryInterface : function (iid) {
+  QueryInterface : function(iid) {
     const interfaces = [Ci.nsIProtocolProxyCallback, Ci.nsISupports];
 
     if (!interfaces.some( function(v) { return iid.equals(v); } ))
       throw SpecialPowers.Cr.NS_ERROR_NO_INTERFACE;
     return this;
   },
 
-  onProxyAvailable : function (req, uri, pi, status) {
+  onProxyAvailable : function(req, uri, pi, status) {
     initLogins(pi);
 
     // I'm cheating a bit here... We should probably do some magic foo to get
     // something implementing nsIProxiedProtocolHandler and then call
     // NewProxiedChannel(), so we have something that's definately a proxied
     // channel. But Mochitests use a proxy for a number of hosts, so just
     // requesting a normal channel will give us a channel that's proxied.
     // The proxyChannel needs to move to at least on-modify-request to
--- a/toolkit/components/passwordmgr/test/prompt_common.js
+++ b/toolkit/components/passwordmgr/test/prompt_common.js
@@ -21,26 +21,26 @@ function startCallbackTimer() {
 
     // Use a timer to invoke a callback to twiddle the authentication dialog
     timer = Cc["@mozilla.org/timer;1"].createInstance(Ci.nsITimer);
     timer.init(observer, dialogDelay, Ci.nsITimer.TYPE_ONE_SHOT);
 }
 
 
 var observer = SpecialPowers.wrapCallbackObject({
-    QueryInterface : function (iid) {
+    QueryInterface : function(iid) {
         const interfaces = [Ci.nsIObserver,
                             Ci.nsISupports, Ci.nsISupportsWeakReference];
 
         if (!interfaces.some( function(v) { return iid.equals(v); } ))
             throw SpecialPowers.Components.results.NS_ERROR_NO_INTERFACE;
         return this;
     },
 
-    observe : function (subject, topic, data) {
+    observe : function(subject, topic, data) {
         var doc = getDialogDoc();
         if (doc)
             handleDialog(doc, testNum);
         else
             startCallbackTimer(); // try again in a bit
     }
 });
 
--- a/toolkit/components/passwordmgr/test/test_prompt_async.html
+++ b/toolkit/components/passwordmgr/test/test_prompt_async.html
@@ -34,17 +34,17 @@
          *
          * NB: Because the constructor (above) adds |this| directly as an observer,
          * we need to do SpecialPowers.wrapCallbackObject directly on the prototype.
          */
         dialogMonitor.prototype = SpecialPowers.wrapCallbackObject({
             windowsOpen : 0,
             windowsRegistered : 0,
 
-            QueryInterface : function (iid) {
+            QueryInterface : function(iid) {
                 const interfaces = [Ci.nsIObserver, Ci.nsISupports];
 
                 if (!interfaces.some( function(v) { return iid.equals(v); } ))
                         throw SpecialPowers.Cr.NS_ERROR_NO_INTERFACE;
                 return this;
             },
 
             observe: function(subject, topic, data) {
@@ -125,25 +125,25 @@
                                        .getService(Ci.nsIHttpAuthManager);
             authMgr.clearAll();
 
             monitor.shutdown();
             SimpleTest.finish();
         }
 
 	var resolveCallback = SpecialPowers.wrapCallbackObject({
-	QueryInterface : function (iid) {
+	QueryInterface : function(iid) {
 	const interfaces = [Ci.nsIProtocolProxyCallback, Ci.nsISupports];
 
         if (!interfaces.some( function(v) { return iid.equals(v); } ))
           throw SpecialPowers.Cr.NS_ERROR_NO_INTERFACE;
 	  return this;
 	},
 
-	onProxyAvailable : function (req, uri, pi, status) {
+	onProxyAvailable : function(req, uri, pi, status) {
           initLogins(pi);
           doTest(testNum);
 	}
 	});
 
 	function startup() {
             // Need to allow for arbitrary network servers defined in PAC instead of a hardcoded moz-proxy.
             var channel = NetUtil.newChannel({
@@ -157,17 +157,17 @@
             pps.asyncResolve(channel, 0, resolveCallback);
 	}
 
         // --------------- Test loop spin ----------------
         var testNum = 1;
         var iframe1;
         var iframe2a;
         var iframe2b;
-        window.onload = function () {
+        window.onload = function() {
             iframe1 = document.getElementById("iframe1");
             iframe2a = document.getElementById("iframe2a");
             iframe2b = document.getElementById("iframe2b");
             iframe1.onload = onFrameLoad;
             iframe2a.onload = onFrameLoad;
             iframe2b.onload = onFrameLoad;
 
 	    startup();
--- a/toolkit/components/passwordmgr/test/test_xhr.html
+++ b/toolkit/components/passwordmgr/test/test_xhr.html
@@ -169,17 +169,17 @@ function doTest() {
     default:
         finishTest();
   }
 }
 
 function makeRequest(uri) {
   var request = new XMLHttpRequest();
   request.open("GET", uri, true);
-  request.onreadystatechange = function () {
+  request.onreadystatechange = function() {
     if (request.readyState == 4)
       xhrLoad(request.responseXML);
   };
   request.send(null);
 }
 
 
 initLogins();
--- a/toolkit/components/passwordmgr/test/unit/head.js
+++ b/toolkit/components/passwordmgr/test/unit/head.js
@@ -74,17 +74,17 @@ function getTempFile(aLeafName)
   let [base, ext] = DownloadPaths.splitBaseNameAndExtension(aLeafName);
   let leafName = base + "-" + gFileCounter + ext;
   gFileCounter++;
 
   // Get a file reference under the temporary directory for this test file.
   let file = FileUtils.getFile("TmpD", [leafName]);
   do_check_false(file.exists());
 
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     if (file.exists()) {
       file.remove(false);
     }
   });
 
   return file;
 }
 
--- a/toolkit/components/passwordmgr/test/unit/test_module_LoginImport.js
+++ b/toolkit/components/passwordmgr/test/unit/test_module_LoginImport.js
@@ -141,18 +141,18 @@ add_task(function* test_import()
   }
 
   // The "load" method must be called before importing data.
   yield store.load();
   yield new LoginImport(store, loginsSqlite).import();
 
   // Verify that every login in the test data has a matching imported row.
   do_check_eq(loginList.length, store.data.logins.length);
-  do_check_true(loginList.every(function (loginInfo) {
-    return store.data.logins.some(function (loginDataItem) {
+  do_check_true(loginList.every(function(loginInfo) {
+    return store.data.logins.some(function(loginDataItem) {
       let username = gLoginManagerCrypto.decrypt(loginDataItem.encryptedUsername);
       let password = gLoginManagerCrypto.decrypt(loginDataItem.encryptedPassword);
       return loginDataItem.hostname == loginInfo.hostname &&
              loginDataItem.httpRealm == loginInfo.httpRealm &&
              loginDataItem.formSubmitURL == loginInfo.formSubmitURL &&
              loginDataItem.usernameField == loginInfo.usernameField &&
              loginDataItem.passwordField == loginInfo.passwordField &&
              username == loginInfo.username &&
--- a/toolkit/components/passwordmgr/test/unit/test_notifications.js
+++ b/toolkit/components/passwordmgr/test/unit/test_notifications.js
@@ -3,17 +3,17 @@
  */
 
 var expectedNotification;
 var expectedData;
 
 var TestObserver = {
   QueryInterface : XPCOMUtils.generateQI([Ci.nsIObserver, Ci.nsISupportsWeakReference]),
 
-  observe : function (subject, topic, data) {
+  observe : function(subject, topic, data) {
     do_check_eq(topic, "passwordmgr-storage-changed");
     do_check_eq(data, expectedNotification);
 
     switch (data) {
         case "addLogin":
             do_check_true(subject instanceof Ci.nsILoginInfo);
             do_check_true(subject instanceof Ci.nsILoginMetaInfo);
             do_check_true(expectedData.equals(subject)); // nsILoginInfo.equals()
--- a/toolkit/components/passwordmgr/test/unit/test_telemetry.js
+++ b/toolkit/components/passwordmgr/test/unit/test_telemetry.js
@@ -105,17 +105,17 @@ function testHistogram(histogramId, expe
 
 /**
  * Enable local telemetry recording for the duration of the tests, and prepare
  * the test data that will be used by the following tests.
  */
 add_task(function test_initialize() {
   let oldCanRecord = Services.telemetry.canRecordExtended;
   Services.telemetry.canRecordExtended = true;
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     Services.telemetry.canRecordExtended = oldCanRecord;
   });
 
   let uniqueNumber = 1;
   for (let loginModifications of StatisticsTestData) {
     loginModifications.hostname = `http://${uniqueNumber++}.example.com`;
     Services.logins.addLogin(TestData.formLogin(loginModifications));
   }
@@ -165,17 +165,17 @@ add_task(function test_disabledHosts_sta
   testHistogram("PWMGR_BLOCKLIST_NUM_SITES", { 0: 1 });
 });
 
 /**
  * Tests the collection of statistics related to general settings.
  */
 add_task(function test_settings_statistics() {
   let oldRememberSignons = Services.prefs.getBoolPref("signon.rememberSignons");
-  do_register_cleanup(function () {
+  do_register_cleanup(function() {
     Services.prefs.setBoolPref("signon.rememberSignons", oldRememberSignons);
   });
 
   // Repeat the operation twice per value to test that histograms are reset.
   for (let remember of [false, true, false, true]) {
     // This change should be observed immediately by the login service.
     Services.prefs.setBoolPref("signon.rememberSignons", remember);
 
--- a/toolkit/components/perfmonitoring/tests/browser/browser_AddonWatcher.js
+++ b/toolkit/components/perfmonitoring/tests/browser/browser_AddonWatcher.js
@@ -63,17 +63,17 @@ add_task(function* init() {
       Preferences.reset(k);
     }
   });
 
   let oldCanRecord = Services.telemetry.canRecordExtended;
   Services.telemetry.canRecordExtended = true;
   AddonWatcher.init();
 
-  registerCleanupFunction(function () {
+  registerCleanupFunction(function() {
     AddonWatcher.paused = true;
     Services.telemetry.canRecordExtended = oldCanRecord;
   });
 });
 
 // Utility function to burn some resource, trigger a reaction of the add-on watcher
 // and check both its notification and telemetry.
 let burn_rubber = Task.async(function*({histogramName, topic, expectedMinSum}) {
--- a/toolkit/components/places/BookmarkHTMLUtils.jsm
+++ b/toolkit/components/places/BookmarkHTMLUtils.jsm
@@ -1032,29 +1032,29 @@ BookmarkExporter.prototype = {
       } finally {
         out.close();
       }
     }.bind(this));
   },
 
   _converterOut: null,
 
-  _write: function (aText) {
+  _write: function(aText) {
     this._converterOut.writeString(aText || "");
   },
 
-  _writeAttribute: function (aName, aValue) {
+  _writeAttribute: function(aName, aValue) {
     this._write(' ' +  aName + '="' + aValue + '"');
   },
 
-  _writeLine: function (aText) {
+  _writeLine: function(aText) {
     this._write(aText + "\n");
   },
 
-  _writeHeader: function () {
+  _writeHeader: function() {
     this._writeLine("<!DOCTYPE NETSCAPE-Bookmark-file-1>");
     this._writeLine("<!-- This is an automatically generated file.");
     this._writeLine("     It will be read and overwritten.");
     this._writeLine("     DO NOT EDIT! -->");
     this._writeLine('<META HTTP-EQUIV="Content-Type" CONTENT="text/html; ' +
                     'charset=UTF-8">');
     this._writeLine("<TITLE>Bookmarks</TITLE>");
   },
@@ -1097,25 +1097,25 @@ BookmarkExporter.prototype = {
       } else if (child.type == PlacesUtils.TYPE_X_MOZ_PLACE_SEPARATOR) {
         this._writeSeparator(child, localIndent);
       } else {
         yield this._writeItem(child, localIndent);
       }
     }
   },
 
-  _writeSeparator: function (aItem, aIndent) {
+  _writeSeparator: function(aItem, aIndent) {
     this._write(aIndent + "<HR");
     // We keep exporting separator titles, but don't support them anymore.
     if (aItem.title)
       this._writeAttribute("NAME", escapeHtmlEntities(aItem.title));
     this._write(">");
   },
 
-  _writeLivemark: function (aItem, aIndent) {
+  _writeLivemark: function(aItem, aIndent) {
     this._write(aIndent + "<DT><A");
     let feedSpec = aItem.annos.find(anno => anno.name == PlacesUtils.LMANNO_FEEDURI).value;
     this._writeAttribute("FEEDURL", escapeUrl(feedSpec));
     let siteSpecAnno = aItem.annos.find(anno => anno.name == PlacesUtils.LMANNO_SITEURI);
     if (siteSpecAnno)
       this._writeAttribute("HREF", escapeUrl(siteSpecAnno.value));
     this._writeLine(">" + escapeHtmlEntities(aItem.title) + "</A>");
     this._writeDescription(aItem, aIndent);
@@ -1145,17 +1145,17 @@ BookmarkExporter.prototype = {
     if (aItem.charset)
       this._writeAttribute("LAST_CHARSET", escapeHtmlEntities(aItem.charset));
     if (aItem.tags)
       this._writeAttribute("TAGS", aItem.tags);
     this._writeLine(">" + escapeHtmlEntities(aItem.title) + "</A>");
     this._writeDescription(aItem, aIndent);
   },
 
-  _writeDateAttributes: function (aItem) {
+  _writeDateAttributes: function(aItem) {
     if (aItem.dateAdded)
       this._writeAttribute("ADD_DATE",
                            Math.floor(aItem.dateAdded / MICROSEC_PER_SEC));
     if (aItem.lastModified)
       this._writeAttribute("LAST_MODIFIED",
                            Math.floor(aItem.lastModified / MICROSEC_PER_SEC));
   },
 
@@ -1174,15 +1174,15 @@ BookmarkExporter.prototype = {
 
     if (!favicon.uri.schemeIs("chrome") && favicon.dataLen > 0) {
       let faviconContents = "data:image/png;base64," +
         base64EncodeString(String.fromCharCode.apply(String, favicon.data));
       this._writeAttribute("ICON", faviconContents);
     }
   },
 
-  _writeDescription: function (aItem, aIndent) {
+  _writeDescription: function(aItem, aIndent) {
     let descriptionAnno = aItem.annos &&
                           aItem.annos.find(anno => anno.name == DESCRIPTION_ANNO);
     if (descriptionAnno)
       this._writeLine(aIndent + "<DD>" + escapeHtmlEntities(descriptionAnno.value));
   }
 };
--- a/toolkit/components/places/History.jsm
+++ b/toolkit/components/places/History.jsm
@@ -125,17 +125,17 @@ this.History = Object.freeze({
    * @resolves (PageInfo | null) If the page could be found, the information
    *      on that page. Note that this `PageInfo` does NOT contain the visit
    *      data (i.e. `visits` is `undefined`).
    *
    * @throws (Error)
    *      If `guidOrURI` does not have the expected type or if it is a string
    *      that may be parsed neither as a valid URL nor as a valid GUID.
    */
-  fetch: function (guidOrURI) {
+  fetch: function(guidOrURI) {
     throw new Error("Method not implemented");
   },
 
   /**
    * Adds a number of visits for a single page.
    *
    * Any change may be observed through nsINavHistoryObserver
    *
@@ -170,17 +170,17 @@ this.History = Object.freeze({
    * @throws (Error)
    *      If `pageInfo` does not have a `visits` property or if the
    *      value of `visits` is ill-typed or is an empty array.
    * @throws (Error)
    *      If an element of `visits` has an invalid `date`.
    * @throws (Error)
    *      If an element of `visits` has an invalid `transition`.
    */
-  insert: function (pageInfo) {
+  insert: function(pageInfo) {
     if (typeof pageInfo != "object" || !pageInfo) {
       throw new TypeError("pageInfo must be an object");
     }
 
     let info = validatePageInfo(pageInfo);
 
     return PlacesUtils.withConnectionWrapper("History.jsm: insert",
       db => insert(db, info));
@@ -226,17 +226,17 @@ this.History = Object.freeze({
    * @throws (Error)
    *      If a `PageInfo` does not have a `visits` property or if the
    *      value of `visits` is ill-typed or is an empty array.
    * @throws (Error)
    *      If an element of `visits` has an invalid `date`.
    * @throws (Error)
    *      If an element of `visits` has an invalid `transition`.
    */
-  insertMany: function (pageInfos, onResult, onError) {
+  insertMany: function(pageInfos, onResult, onError) {
     let infos = [];
 
     if (!Array.isArray(pageInfos)) {
       throw new TypeError("pageInfos must be an array");
     }
     if (!pageInfos.length) {
       throw new TypeError("pageInfos may not be an empty array");
     }
@@ -276,17 +276,17 @@ this.History = Object.freeze({
    *      A promise resolved once the operation is complete.
    * @resolve (bool)
    *      `true` if at least one page was removed, `false` otherwise.
    * @throws (TypeError)
    *       If `pages` has an unexpected type or if a string provided
    *       is neither a valid GUID nor a valid URI or if `pages`
    *       is an empty array.
    */
-  remove: function (pages, onResult = null) {
+  remove: function(pages, onResult = null) {
     // Normalize and type-check arguments
     if (Array.isArray(pages)) {
       if (pages.length == 0) {
         throw new TypeError("Expected at least one page");
       }
     } else {
       pages = [pages];
     }
--- a/toolkit/components/places/PlacesDBUtils.jsm
+++ b/toolkit/components/places/PlacesDBUtils.jsm
@@ -132,17 +132,17 @@ this.PlacesDBUtils = {
    *        Tasks object to execute.
    */
   _refreshUI: function PDBU__refreshUI(aTasks)
   {
     let tasks = new Tasks(aTasks);
 
     // Send batch update notifications to update the UI.
     PlacesUtils.history.runInBatchMode({
-      runBatched: function (aUserData) {}
+      runBatched: function(aUserData) {}
     }, null);
     PlacesDBUtils._executeTasks(tasks);
   },
 
   _handleError: function PDBU__handleError(aError)
   {
     Cu.reportError("Async statement execution returned with '" +
                    aError.result + "', '" + aError.message + "'");
@@ -157,19 +157,19 @@ this.PlacesDBUtils = {
   reindex: function PDBU_reindex(aTasks)
   {
     let tasks = new Tasks(aTasks);
     tasks.log("> Reindex");
 
     let stmt = DBConn.createAsyncStatement("REINDEX");
     stmt.executeAsync({
       handleError: PlacesDBUtils._handleError,
-      handleResult: function () {},
+      handleResult: function() {},
 
-      handleCompletion: function (aReason)
+      handleCompletion: function(aReason)
       {
         if (aReason == Ci.mozIStorageStatementCallback.REASON_FINISHED) {
           tasks.log("+ The database has been reindexed");
         }
         else {
           tasks.log("- Unable to reindex database");
         }
 
@@ -203,23 +203,23 @@ this.PlacesDBUtils = {
     tasks.log("> Integrity check");
 
     // Run a integrity check, but stop at the first error.
     let stmt = DBConn.createAsyncStatement("PRAGMA integrity_check(1)");
     stmt.executeAsync({
       handleError: PlacesDBUtils._handleError,
 
       _corrupt: false,
-      handleResult: function (aResultSet)
+      handleResult: function(aResultSet)
       {
         let row = aResultSet.getNextRow();
         this._corrupt = row.getResultByIndex(0) != "ok";
       },
 
-      handleCompletion: function (aReason)
+      handleCompletion: function(aReason)
       {
         if (aReason == Ci.mozIStorageStatementCallback.REASON_FINISHED) {
           if (this._corrupt) {
             tasks.log("- The database is corrupt");
             if (aSkipReindex) {
               tasks.log("- Unable to fix corruption, database will be replaced on next startup");
               Services.prefs.setBoolPref("places.database.replaceOnStartup", true);
               tasks.clear();
@@ -255,19 +255,19 @@ this.PlacesDBUtils = {
   checkCoherence: function PDBU_checkCoherence(aTasks)
   {
     let tasks = new Tasks(aTasks);
     tasks.log("> Coherence check");
 
     let stmts = PlacesDBUtils._getBoundCoherenceStatements();
     DBConn.executeAsync(stmts, stmts.length, {
       handleError: PlacesDBUtils._handleError,
-      handleResult: function () {},
+      handleResult: function() {},
 
-      handleCompletion: function (aReason)
+      handleCompletion: function(aReason)
       {
         if (aReason == Ci.mozIStorageStatementCallback.REASON_FINISHED) {
           tasks.log("+ The database is coherent");
         }
         else {
           tasks.log("- Unable to check database coherence");
           tasks.clear();
         }
@@ -743,19 +743,19 @@ this.PlacesDBUtils = {
     let DBFile = Services.dirsvc.get("ProfD", Ci.nsILocalFile);
     DBFile.append("places.sqlite");
     tasks.log("Initial database size is " +
               parseInt(DBFile.fileSize / 1024) + " KiB");
 
     let stmt = DBConn.createAsyncStatement("VACUUM");
     stmt.executeAsync({
       handleError: PlacesDBUtils._handleError,
-      handleResult: function () {},
+      handleResult: function() {},
 
-      handleCompletion: function (aReason)
+      handleCompletion: function(aReason)
       {
         if (aReason == Ci.mozIStorageStatementCallback.REASON_FINISHED) {
           tasks.log("+ The database has been vacuumed");
           let vacuumedDBFile = Services.dirsvc.get("ProfD", Ci.nsILocalFile);
           vacuumedDBFile.append("places.sqlite");
           tasks.log("Final database size is " +
                     parseInt(vacuumedDBFile.fileSize / 1024) + " KiB");
         }
@@ -779,17 +779,17 @@ this.PlacesDBUtils = {
   expire: function PDBU_expire(aTasks)
   {
     let tasks = new Tasks(aTasks);
     tasks.log("> Orphans expiration");
 
     let expiration = Cc["@mozilla.org/places/expiration;1"].
                      getService(Ci.nsIObserver);
 
-    Services.obs.addObserver(function (aSubject, aTopic, aData) {
+    Services.obs.addObserver(function(aSubject, aTopic, aData) {
       Services.obs.removeObserver(arguments.callee, aTopic);
       tasks.log("+ Database cleaned up");
       PlacesDBUtils._executeTasks(tasks);
     }, PlacesUtils.TOPIC_EXPIRATION_FINISHED, false);
 
     // Force an orphans expiration step.
     expiration.observe(null, "places-debug-start-expiration", 0);
   },
@@ -809,17 +809,17 @@ this.PlacesDBUtils = {
     DBFile.append("places.sqlite");
     tasks.log("Database size is " + parseInt(DBFile.fileSize / 1024) + " KiB");
 
     [ "user_version"
     , "page_size"
     , "cache_size"
     , "journal_mode"
     , "synchronous"
-    ].forEach(function (aPragma) {
+    ].forEach(function(aPragma) {
       let stmt = DBConn.createStatement("PRAGMA " + aPragma);
       stmt.executeStep();
       tasks.log(aPragma + " is " + stmt.getString(0));
       stmt.finalize();
     });
 
     // Get maximum number of unique URIs.
     try {
@@ -924,45 +924,45 @@ this.PlacesDBUtils = {
                       ) * 100 / (
                       SELECT count(*) FROM moz_bookmarks b
                       JOIN moz_bookmarks t ON t.id = b.parent
                       AND t.parent <> :tags_folder
                       WHERE b.type = :type_bookmark
                     )), 0)` },
 
       { histogram: "PLACES_DATABASE_FILESIZE_MB",
-        callback: function () {
+        callback: function() {
           let DBFile = Services.dirsvc.get("ProfD", Ci.nsILocalFile);
           DBFile.append("places.sqlite");
           return parseInt(DBFile.fileSize / BYTES_PER_MEBIBYTE);
         }
       },
 
       { histogram: "PLACES_DATABASE_PAGESIZE_B",
         query:     "PRAGMA page_size /* PlacesDBUtils.jsm PAGESIZE_B */" },
 
       { histogram: "PLACES_DATABASE_SIZE_PER_PAGE_B",
         query:     "PRAGMA page_count",
-        callback: function (aDbPageCount) {
+        callback: function(aDbPageCount) {
           // Note that the database file size would not be meaningful for this
           // calculation, because the file grows in fixed-size chunks.
           let dbPageSize = probeValues.PLACES_DATABASE_PAGESIZE_B;
           let placesPageCount = probeValues.PLACES_PAGES_COUNT;
           return Math.round((dbPageSize * aDbPageCount) / placesPageCount);
         }
       },
 
       { histogram: "PLACES_ANNOS_BOOKMARKS_COUNT",
         query:     "SELECT count(*) FROM moz_items_annos" },
 
       { histogram: "PLACES_ANNOS_PAGES_COUNT",
         query:     "SELECT count(*) FROM moz_annos" },
 
       { histogram: "PLACES_MAINTENANCE_DAYSFROMLAST",
-        callback: function () {
+        callback: function() {
           try {
             let lastMaintenance = Services.prefs.getIntPref("places.database.lastMaintenance");
             let nowSeconds = parseInt(Date.now() / 1000);
             return parseInt((nowSeconds - lastMaintenance) / 86400);
           } catch (ex) {
             return 60;
           }
         }
@@ -990,21 +990,21 @@ this.PlacesDBUtils = {
           if (probe.query.indexOf(":" + param) > 0) {
             stmt.params[param] = params[param];
           }
         }
 
         try {
           stmt.executeAsync({
             handleError: reject,
-            handleResult: function (aResultSet) {
+            handleResult: function(aResultSet) {
               let row = aResultSet.getNextRow();
               resolve([probe, row.getResultByIndex(0)]);
             },
-            handleCompletion: function () {}
+            handleCompletion: function() {}
           });
         } finally {
           stmt.finalize();
         }
       });
 
       // Report the result of the probe through Telemetry.
       // The resulting promise cannot reject.
--- a/toolkit/components/places/PlacesSearchAutocompleteProvider.jsm
+++ b/toolkit/components/places/PlacesSearchAutocompleteProvider.jsm
@@ -33,17 +33,17 @@ const SearchAutocompleteProviderInternal
    */
   aliasMatches: null,
 
   /**
    * Object for the default search match.
    **/
   defaultMatch: null,
 
-  initialize: function () {
+  initialize: function() {
     return new Promise((resolve, reject) => {
       Services.search.init(status => {
         if (!Components.isSuccessCode(status)) {
           reject(new Error("Unable to initialize search service."));
         }
 
         try {
           // The initial loading of the search engines must succeed.
@@ -57,27 +57,27 @@ const SearchAutocompleteProviderInternal
           reject(ex);
         }
       });
     });
   },
 
   initialized: false,
 
-  observe: function (subject, topic, data) {
+  observe: function(subject, topic, data) {
     switch (data) {
       case "engine-added":
       case "engine-changed":
       case "engine-removed":
       case "engine-current":
         this._refresh();
     }
   },
 
-  _refresh: function () {
+  _refresh: function() {
     this.priorityMatches = [];
     this.aliasMatches = [];
     this.defaultMatch = null;
 
     let currentEngine = Services.search.currentEngine;
     // This can be null in XCPShell.
     if (currentEngine) {
       this.defaultMatch = {
@@ -86,17 +86,17 @@ const SearchAutocompleteProviderInternal
       }
     }
 
     // The search engines will always be processed in the order returned by the
     // search service, which can be defined by the user.
     Services.search.getVisibleEngines().forEach(e => this._addEngine(e));
   },
 
-  _addEngine: function (engine) {
+  _addEngine: function(engine) {
     if (engine.alias) {
       this.aliasMatches.push({
         alias: engine.alias,
         engineName: engine.name,
         iconUrl: engine.iconURI ? engine.iconURI.spec : null,
       });
     }
 
@@ -187,17 +187,17 @@ SearchSuggestionControllerWrapper.protot
 var gInitializationPromise = null;
 
 this.PlacesSearchAutocompleteProvider = Object.freeze({
   /**
    * Starts initializing the component and returns a promise that is resolved or
    * rejected when initialization finished.  The same promise is returned if
    * this function is called multiple times.
    */
-  ensureInitialized: function () {
+  ensureInitialized: function() {
     if (!gInitializationPromise) {
       gInitializationPromise = SearchAutocompleteProviderInternal.initialize();
     }
     return gInitializationPromise;
   },
 
   /**
    * Matches a given string to an item that should be included by URL search
@@ -268,17 +268,17 @@ this.PlacesSearchAutocompleteProvider = 
    *         }
    *
    * @remarks The asynchronous ensureInitialized function must be called before
    *          this synchronous method can be used.
    *
    * @note This API function needs to be synchronous because it is called inside
    *       a row processing callback of Sqlite.jsm, in UnifiedComplete.js.
    */
-  parseSubmissionURL: function (url) {
+  parseSubmissionURL: function(url) {
     if (!SearchAutocompleteProviderInternal.initialized) {
       throw new Error("The component has not been initialized.");
     }
 
     let parseUrlResult = Services.search.parseSubmissionURL(url);
     return parseUrlResult.engine && {
       engineName: parseUrlResult.engine.name,
       terms: parseUrlResult.terms,
--- a/toolkit/components/places/PlacesSyncUtils.jsm
+++ b/toolkit/components/places/PlacesSyncUtils.jsm
@@ -880,17 +880,17 @@ var getAnno = Task.async(function* (guid
     JOIN moz_anno_attributes n ON n.id = a.anno_attribute_id
     JOIN moz_bookmarks b ON b.id = a.item_id
     WHERE b.guid = :guid AND
           n.name = :anno`,
     { guid, anno });
   return rows.length ? rows[0].getResultByName("content") : null;
 });
 
-var tagItem = Task.async(function (item, tags) {
+var tagItem = Task.async(function(item, tags) {
   if (!item.url) {
     return [];
   }
 
   // Remove leading and trailing whitespace, then filter out empty tags.
   let newTags = tags.map(tag => tag.trim()).filter(Boolean);
 
   // Removing the last tagged item will also remove the tag. To preserve
--- a/toolkit/components/places/PlacesTransactions.jsm
+++ b/toolkit/components/places/PlacesTransactions.jsm
@@ -216,17 +216,17 @@ TransactionsHistory.__proto__ = {
 
   /**
    * Proxify a transaction object for consumers.
    * @param aRawTransaction
    *        the raw transaction object.
    * @return the proxified transaction object.
    * @see getRawTransaction for retrieving the raw transaction.
    */
-  proxifyTransaction: function (aRawTransaction) {
+  proxifyTransaction: function(aRawTransaction) {
     let proxy = Object.freeze({
       transact() {
         return TransactionsManager.transact(this);
       }
     });
     this.proxifiedToRaw.set(proxy, aRawTransaction);
     return proxy;
   },
@@ -662,17 +662,17 @@ var TransactionsManager = {
  *     all this bureaucracy while still validating input appropriately.
  */
 function DefineTransaction(aRequiredProps = [], aOptionalProps = []) {
   for (let prop of [...aRequiredProps, ...aOptionalProps]) {
     if (!DefineTransaction.inputProps.has(prop))
       throw new Error("Property '" + prop + "' is not defined");
   }
 
-  let ctor = function (aInput) {
+  let ctor = function(aInput) {
     // We want to support both syntaxes:
     // let t = new PlacesTransactions.NewBookmark(),
     // let t = PlacesTransactions.NewBookmark()
     if (this == PlacesTransactions)
       return new ctor(aInput);
 
     if (aRequiredProps.length > 0 || aOptionalProps.length > 0) {
       // Bind the input properties to the arguments of execute.
@@ -704,17 +704,17 @@ DefineTransaction.indexValidate =
                           v >= PlacesUtils.bookmarks.DEFAULT_INDEX);
 DefineTransaction.guidValidate =
   simpleValidateFunc(v => /^[a-zA-Z0-9\-_]{12}$/.test(v));
 
 function isPrimitive(v) {
   return v === null || (typeof(v) != "object" && typeof(v) != "function");
 }
 
-DefineTransaction.annotationObjectValidate = function (obj) {
+DefineTransaction.annotationObjectValidate = function(obj) {
   let checkProperty = (aPropName, aRequired, aCheckFunc) => {
     if (aPropName in obj)
       return aCheckFunc(obj[aPropName]);
 
     return !aRequired;
   };
 
   if (obj &&
@@ -736,66 +736,66 @@ DefineTransaction.urlValidate = function
   if (url instanceof Components.interfaces.nsIURI)
     return url;
   let spec = url instanceof URL ? url.href : url;
   return NetUtil.newURI(spec);
 };
 
 DefineTransaction.inputProps = new Map();
 DefineTransaction.defineInputProps =
-function (aNames, aValidationFunction, aDefaultValue) {
+function(aNames, aValidationFunction, aDefaultValue) {
   for (let name of aNames) {
     // Workaround bug 449811.
     let propName = name;
     this.inputProps.set(propName, {
-      validateValue: function (aValue) {
+      validateValue: function(aValue) {
         if (aValue === undefined)
           return aDefaultValue;
         try {
           return aValidationFunction(aValue);
         }
         catch (ex) {
           throw new Error(`Invalid value for input property ${propName}`);
         }
       },
 
-      validateInput: function (aInput, aRequired) {
+      validateInput: function(aInput, aRequired) {
         if (aRequired && !(propName in aInput))
           throw new Error(`Required input property is missing: ${propName}`);
         return this.validateValue(aInput[propName]);
       },
 
       isArrayProperty: false
     });
   }
 };
 
 DefineTransaction.defineArrayInputProp =
-function (aName, aBasePropertyName) {
+function(aName, aBasePropertyName) {
   let baseProp = this.inputProps.get(aBasePropertyName);
   if (!baseProp)
     throw new Error(`Unknown input property: ${aBasePropertyName}`);
 
   this.inputProps.set(aName, {
-    validateValue: function (aValue) {
+    validateValue: function(aValue) {
       if (aValue == undefined)
         return [];
 
       if (!Array.isArray(aValue))
         throw new Error(`${aName} input property value must be an array`);
 
       // This also takes care of abandoning the global scope of the input
       // array (through Array.prototype).
       return aValue.map(baseProp.validateValue);
     },
 
     // We allow setting either the array property itself (e.g. urls), or a
     // single element of it (url, in that example), that is then transformed
     // into a single-element array.
-    validateInput: function (aInput, aRequired) {
+    validateInput: function(aInput, aRequired) {
       if (aName in aInput) {
         // It's not allowed to set both though.
         if (aBasePropertyName in aInput) {
           throw new Error(`It is not allowed to set both ${aName} and
                           ${aBasePropertyName} as  input properties`);
         }
         let array = this.validateValue(aInput[aName]);
         if (aRequired && array.length == 0) {
@@ -815,22 +815,22 @@ function (aName, aBasePropertyName) {
       return [];
     },
 
     isArrayProperty: true
   });
 };
 
 DefineTransaction.validatePropertyValue =
-function (aProp, aInput, aRequired) {
+function(aProp, aInput, aRequired) {
   return this.inputProps.get(aProp).validateInput(aInput, aRequired);
 };
 
 DefineTransaction.getInputObjectForSingleValue =
-function (aInput, aRequiredProps, aOptionalProps) {
+function(aInput, aRequiredProps, aOptionalProps) {
   // The following input forms may be deduced from a single value:
   // * a single required property with or without optional properties (the given
   //   value is set to the required property).
   // * a single optional property with no required properties.
   if (aRequiredProps.length > 1 ||
       (aRequiredProps.length == 0 && aOptionalProps.length > 1)) {
     throw new Error("Transaction input isn't an object");
   }
@@ -839,17 +839,17 @@ function (aInput, aRequiredProps, aOptio
                  aRequiredProps[0] : aOptionalProps[0];
   let propValue =
     this.inputProps.get(propName).isArrayProperty && !Array.isArray(aInput) ?
     [aInput] : aInput;
   return { [propName]: propValue };
 };
 
 DefineTransaction.verifyInput =
-function (aInput, aRequiredProps = [], aOptionalProps = []) {
+function(aInput, aRequiredProps = [], aOptionalProps = []) {
   if (aRequiredProps.length == 0 && aOptionalProps.length == 0)
     return {};
 
   // If there's just a single required/optional property, we allow passing it
   // as is, so, for example, one could do PlacesTransactions.RemoveItem(myGuid)
   // rather than PlacesTransactions.RemoveItem({ guid: myGuid}).
   // This shortcut isn't supported for "complex" properties - e.g. one cannot
   // pass an annotation object this way (note there is no use case for this at
@@ -1079,18 +1079,18 @@ var PT = PlacesTransactions;
  * Optional Input Properties: index, title, keyword, annotations, tags.
  *
  * When this transaction is executed, it's resolved to the new bookmark's GUID.
  */
 PT.NewBookmark = DefineTransaction(["parentGuid", "url"],
                                    ["index", "title", "keyword", "postData",
                                     "annotations", "tags"]);
 PT.NewBookmark.prototype = Object.seal({
-  execute: function (aParentGuid, aURI, aIndex, aTitle,
-                     aKeyword, aPostData, aAnnos, aTags) {
+  execute: function(aParentGuid, aURI, aIndex, aTitle,
+                    aKeyword, aPostData, aAnnos, aTags) {
     return ExecuteCreateItem(this, aParentGuid,
       function* (parentId, guidToRestore = "") {
         let itemId = PlacesUtils.bookmarks.insertBookmark(
           parentId, aURI, aIndex, aTitle, guidToRestore);
 
         if (aKeyword) {
           yield PlacesUtils.keywords.insert({
             url: aURI.spec,
@@ -1123,17 +1123,17 @@ PT.NewBookmark.prototype = Object.seal({
  * Required Input Properties: title, parentGuid.
  * Optional Input Properties: index, annotations.
  *
  * When this transaction is executed, it's resolved to the new folder's GUID.
  */
 PT.NewFolder = DefineTransaction(["parentGuid", "title"],
                                  ["index", "annotations"]);
 PT.NewFolder.prototype = Object.seal({
-  execute: function (aParentGuid, aTitle, aIndex, aAnnos) {
+  execute: function(aParentGuid, aTitle, aIndex, aAnnos) {
     return ExecuteCreateItem(this,  aParentGuid,
       function* (parentId, guidToRestore = "") {
         let itemId = PlacesUtils.bookmarks.createFolder(
           parentId, aTitle, aIndex, guidToRestore);
         if (aAnnos.length > 0)
           PlacesUtils.setAnnotationsForItem(itemId, aAnnos);
         return itemId;
       });
@@ -1146,17 +1146,17 @@ PT.NewFolder.prototype = Object.seal({
  * Required Input Properties: parentGuid.
  * Optional Input Properties: index.
  *
  * When this transaction is executed, it's resolved to the new separator's
  * GUID.
  */
 PT.NewSeparator = DefineTransaction(["parentGuid"], ["index"]);
 PT.NewSeparator.prototype = Object.seal({
-  execute: function (aParentGuid, aIndex) {
+  execute: function(aParentGuid, aIndex) {
     return ExecuteCreateItem(this, aParentGuid,
       function* (parentId, guidToRestore = "") {