Bug 1779145 - Port bug 1667455 to Thunderbird - Expose a "Services" property on all privileged JS scopes (like Cu/Cc/Ci). r=leftmostcat
authorMagnus Melin <mkmelin+mozilla@iki.fi>
Mon, 18 Jul 2022 20:26:40 +1000
changeset 36309 2f4f7096c6f65daf861d6a7bafc7072feeb8690e
parent 36308 67153ea761677871b75c8234175366ad1d6b48b5
child 36310 e5b797ffa45d2ada623da8c9f912f94d8885a45f
push id20108
push usermkmelin@iki.fi
push dateMon, 18 Jul 2022 10:46:51 +0000
treeherdercomm-central@795c1ceaf055 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersleftmostcat
bugs1779145, 1667455
Bug 1779145 - Port bug 1667455 to Thunderbird - Expose a "Services" property on all privileged JS scopes (like Cu/Cc/Ci). r=leftmostcat Changed prettier printWidth to 100 to put Services.jsm on one line, prettified and then grep -rEl "/Services.jsm" --exclude-dir=.hg --exclude-dir=suite --include="*.js" --include="*.jsm" --exclude=".*" . | xargs xargs sed -i -e '/\/Services.jsm/d' Differential Revision: https://phabricator.services.mozilla.com/D151575
calendar/base/backend/CalBackendLoader.jsm
calendar/base/backend/icaljs/calICALJSComponents.js
calendar/base/content/calendar-chrome-startup.js
calendar/base/content/calendar-clipboard.js
calendar/base/content/calendar-command-controller.js
calendar/base/content/calendar-dnd-listener.js
calendar/base/content/calendar-editable-item.js
calendar/base/content/calendar-extract.js
calendar/base/content/calendar-invitations-manager.js
calendar/base/content/calendar-management.js
calendar/base/content/calendar-migration.js
calendar/base/content/calendar-task-tree.js
calendar/base/content/calendar-task-view.js
calendar/base/content/calendar-ui-utils.js
calendar/base/content/calendar-unifinder.js
calendar/base/content/calendar-views-utils.js
calendar/base/content/calendar-views.js
calendar/base/content/dialogs/calendar-alarm-dialog.js
calendar/base/content/dialogs/calendar-creation.js
calendar/base/content/dialogs/calendar-dialog-utils.js
calendar/base/content/dialogs/calendar-event-dialog-attendees.js
calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
calendar/base/content/dialogs/calendar-event-dialog-reminder.js
calendar/base/content/dialogs/calendar-ics-file-dialog.js
calendar/base/content/dialogs/calendar-invitations-dialog.js
calendar/base/content/dialogs/calendar-migration-dialog.js
calendar/base/content/imip-bar.js
calendar/base/content/import-export.js
calendar/base/content/item-editing/calendar-item-editing.js
calendar/base/content/item-editing/calendar-item-iframe.js
calendar/base/content/item-editing/calendar-item-panel.js
calendar/base/content/preferences/alarms.js
calendar/base/content/preferences/categories.js
calendar/base/content/publish.js
calendar/base/content/today-pane.js
calendar/base/content/widgets/calendar-filter.js
calendar/base/content/widgets/calendar-minimonth.js
calendar/base/content/widgets/calendar-modebox.js
calendar/base/content/widgets/datetimepickers.js
calendar/base/modules/calCalendarDeactivator.jsm
calendar/base/modules/calExtract.jsm
calendar/base/modules/calUtils.jsm
calendar/base/modules/utils/calACLUtils.jsm
calendar/base/modules/utils/calAlarmUtils.jsm
calendar/base/modules/utils/calAuthUtils.jsm
calendar/base/modules/utils/calCategoryUtils.jsm
calendar/base/modules/utils/calDateTimeFormatter.jsm
calendar/base/modules/utils/calDateTimeUtils.jsm
calendar/base/modules/utils/calItemUtils.jsm
calendar/base/modules/utils/calIteratorUtils.jsm
calendar/base/modules/utils/calItipUtils.jsm
calendar/base/modules/utils/calL10NUtils.jsm
calendar/base/modules/utils/calPrintUtils.jsm
calendar/base/modules/utils/calProviderDetectionUtils.jsm
calendar/base/modules/utils/calProviderUtils.jsm
calendar/base/modules/utils/calViewUtils.jsm
calendar/base/modules/utils/calWindowUtils.jsm
calendar/base/src/CalAlarmMonitor.jsm
calendar/base/src/CalAlarmService.jsm
calendar/base/src/CalAttachment.jsm
calendar/base/src/CalAttendee.jsm
calendar/base/src/CalCalendarManager.jsm
calendar/base/src/CalDeletedItems.jsm
calendar/base/src/CalEvent.jsm
calendar/base/src/CalIcsParser.jsm
calendar/base/src/CalMetronome.jsm
calendar/base/src/CalMimeConverter.jsm
calendar/base/src/CalProtocolHandler.jsm
calendar/base/src/CalStartupService.jsm
calendar/base/src/CalTimezoneService.jsm
calendar/base/src/CalTodo.jsm
calendar/base/src/calApplicationUtils.js
calendar/base/src/calCachedCalendar.js
calendar/extract/CalExtractParserService.jsm
calendar/itip/CalItipEmailTransport.jsm
calendar/itip/CalItipMessageSender.jsm
calendar/providers/caldav/CalDavCalendar.jsm
calendar/providers/caldav/CalDavProvider.jsm
calendar/providers/caldav/modules/CalDavRequestHandlers.jsm
calendar/providers/ics/CalICSCalendar.jsm
calendar/providers/ics/CalICSProvider.jsm
calendar/providers/storage/CalStorageCalendar.jsm
calendar/providers/storage/CalStorageDatabase.jsm
calendar/providers/storage/calStorageUpgrade.jsm
calendar/test/CalendarTestUtils.jsm
calendar/test/CalendarUtils.jsm
calendar/test/ItemEditingHelpers.jsm
calendar/test/browser/browser_basicFunctionality.js
calendar/test/browser/browser_calDAV_oAuth.js
calendar/test/browser/browser_localICS.js
calendar/test/browser/eventDialog/browser_utf8.js
calendar/test/browser/preferences/browser_alarmDefaultValue.js
calendar/test/browser/providers/head.js
calendar/test/browser/timezones/browser_timezones.js
calendar/test/browser/views/browser_dayView.js
calendar/test/unit/head_consts.js
calendar/test/unit/head_icaljs.js
calendar/test/unit/head_libical.js
calendar/test/unit/providers/head.js
calendar/test/unit/test_alarmservice.js
calendar/test/unit/test_alarmutils.js
calendar/test/unit/test_calmgr.js
calendar/test/unit/test_datetimeformatter.js
calendar/test/unit/test_imip.js
calendar/test/unit/test_invitationutils.js
calendar/test/unit/test_l10n_utils.js
calendar/test/unit/test_webcal.js
chat/components/src/imAccounts.jsm
chat/components/src/imContacts.jsm
chat/components/src/imConversations.jsm
chat/components/src/imCore.jsm
chat/components/src/logger.jsm
chat/components/src/test/test_accounts.js
chat/components/src/test/test_commands.js
chat/components/src/test/test_conversations.js
chat/components/src/test/test_logger.js
chat/content/chat-account-richlistitem.js
chat/content/chat-tooltip.js
chat/content/conversation-browser.js
chat/content/otr-add-fingerprint.js
chat/content/otr-auth.js
chat/content/otr-finger.js
chat/modules/CLib.jsm
chat/modules/InteractiveBrowser.jsm
chat/modules/OTR.jsm
chat/modules/OTRLib.jsm
chat/modules/OTRUI.jsm
chat/modules/ToLocaleFormat.jsm
chat/modules/imContentSink.jsm
chat/modules/imSmileys.jsm
chat/modules/imTextboxUtils.jsm
chat/modules/imThemes.jsm
chat/modules/imXPCOMUtils.jsm
chat/modules/jsProtoHelper.jsm
chat/modules/socket.jsm
chat/modules/test/test_filtering.js
chat/protocols/irc/irc.jsm
chat/protocols/irc/ircCTCP.jsm
chat/protocols/irc/ircCommands.jsm
chat/protocols/irc/ircNonStandard.jsm
chat/protocols/irc/ircServices.jsm
chat/protocols/irc/ircUtils.jsm
chat/protocols/irc/test/test_ctcpDequote.js
chat/protocols/irc/test/test_ctcpQuote.js
chat/protocols/irc/test/test_ircCAP.js
chat/protocols/irc/test/test_ircChannel.js
chat/protocols/irc/test/test_ircCommands.js
chat/protocols/irc/test/test_ircMessage.js
chat/protocols/irc/test/test_ircNonStandard.js
chat/protocols/irc/test/test_ircProtocol.js
chat/protocols/irc/test/test_ircServerTime.js
chat/protocols/irc/test/test_sendBufferedCommand.js
chat/protocols/irc/test/test_setMode.js
chat/protocols/irc/test/test_splitLongMessages.js
chat/protocols/irc/test/test_tryNewNick.js
chat/protocols/matrix/matrix-sdk.jsm
chat/protocols/matrix/matrix.jsm
chat/protocols/matrix/test/head.js
chat/protocols/odnoklassniki/odnoklassniki.jsm
chat/protocols/xmpp/sax.jsm
chat/protocols/xmpp/test/test_dnsSrv.js
chat/protocols/xmpp/test/test_parseJidAndNormalization.js
chat/protocols/xmpp/test/test_saslPrep.js
chat/protocols/xmpp/test/test_xmppXml.js
chat/protocols/xmpp/xmpp-base.jsm
chat/protocols/xmpp/xmpp-commands.jsm
chat/protocols/xmpp/xmpp-session.jsm
mail/actors/LinkClickHandlerChild.jsm
mail/actors/LinkHandlerParent.jsm
mail/actors/MailLinkParent.jsm
mail/actors/PromptParent.jsm
mail/base/content/FilterListDialog.js
mail/base/content/SearchDialog.js
mail/base/content/about3Pane.js
mail/base/content/aboutDialog-appUpdater.js
mail/base/content/aboutDialog.js
mail/base/content/aboutMessage.js
mail/base/content/commandglue.js
mail/base/content/compactFoldersDialog.js
mail/base/content/contentAreaClick.js
mail/base/content/customElements.js
mail/base/content/customizeToolbar.js
mail/base/content/editContactPanel.js
mail/base/content/folderPane.js
mail/base/content/glodaFacetTab.js
mail/base/content/glodaFacetView.js
mail/base/content/macMessengerMenu.js
mail/base/content/mail-offline.js
mail/base/content/mail3PaneWindowCommands.js
mail/base/content/mailContext.js
mail/base/content/mailContextMenus.js
mail/base/content/mailCore.js
mail/base/content/mailWindow.js
mail/base/content/messenger-customization.js
mail/base/content/msgHdrView.js
mail/base/content/msgMail3PaneWindow.js
mail/base/content/msgViewNavigation.js
mail/base/content/multimessageview.js
mail/base/content/newTagDialog.js
mail/base/content/nsContextMenu.js
mail/base/content/printUtils.js
mail/base/content/profileDowngrade.js
mail/base/content/sanitize.js
mail/base/content/spacesToolbar.js
mail/base/content/specialTabs.js
mail/base/content/systemIntegrationDialog.js
mail/base/content/tabmail.js
mail/base/content/troubleshootMode.js
mail/base/content/utilityOverlay.js
mail/base/content/viewSource.js
mail/base/content/viewZoomOverlay.js
mail/base/content/widgets/foldersummary.js
mail/base/content/widgets/gloda-autocomplete-input.js
mail/base/content/widgets/glodaFacet.js
mail/base/content/widgets/header-fields.js
mail/base/content/widgets/mailWidgets.js
mail/base/content/widgets/tabmail-tabs.js
mail/base/content/widgets/tree-listbox.js
mail/base/test/browser/browser_mailContext.js
mail/base/test/browser/browser_orderableTreeListbox.js
mail/base/test/performance/browser_startup.js
mail/base/test/unit/head_mailbase.js
mail/base/test/unit/resources/viewWrapperTestUtils.js
mail/base/test/unit/test_mailGlue_distribution.js
mail/base/test/unit/test_oauth_migration.js
mail/base/test/unit/test_viewWrapper_realFolder.js
mail/components/AboutRedirector.jsm
mail/components/AppIdleManager.jsm
mail/components/MailGlue.jsm
mail/components/MessengerContentHandler.jsm
mail/components/StartupRecorder.jsm
mail/components/about-support/content/aboutSupport.js
mail/components/about-support/content/accounts.js
mail/components/about-support/content/chat.js
mail/components/accountcreation/AccountCreationUtils.jsm
mail/components/accountcreation/CreateInBackend.jsm
mail/components/accountcreation/ExchangeAutoDiscover.jsm
mail/components/accountcreation/FetchConfig.jsm
mail/components/accountcreation/GuessConfig.jsm
mail/components/accountcreation/Sanitizer.jsm
mail/components/accountcreation/content/accountSetup.js
mail/components/accountcreation/test/xpcshell/test_autoconfigFetchDisk.js
mail/components/accountcreation/verifyConfig.jsm
mail/components/activity/ActivityManagerUI.jsm
mail/components/activity/content/activity-widgets.js
mail/components/activity/modules/alertHook.jsm
mail/components/activity/modules/autosync.jsm
mail/components/activity/modules/glodaIndexer.jsm
mail/components/activity/modules/moveCopy.jsm
mail/components/activity/modules/pop3Download.jsm
mail/components/activity/modules/sendLater.jsm
mail/components/addrbook/content/abCommon.js
mail/components/addrbook/content/abSearchDialog.js
mail/components/addrbook/content/abView-new.js
mail/components/addrbook/content/aboutAddressBook.js
mail/components/addrbook/content/addressBookTab.js
mail/components/addrbook/content/menulist-addrbooks.js
mail/components/addrbook/content/vcard-edit/edit.js
mail/components/addrbook/test/browser/browser_cardDAV_oAuth.js
mail/components/cloudfile/cloudFileAccounts.jsm
mail/components/compose/content/MsgComposeCommands.js
mail/components/compose/content/addressingWidgetOverlay.js
mail/components/compose/content/bigFileObserver.js
mail/components/compose/content/dialogs/EdImageLinkLoader.js
mail/components/compose/content/editorUtilities.js
mail/components/customizableui/CustomizableUI.jsm
mail/components/customizableui/CustomizableWidgets.jsm
mail/components/customizableui/PanelMultiView.jsm
mail/components/customizableui/SearchWidgetTracker.jsm
mail/components/customizableui/content/panelUI.js
mail/components/enterprisepolicies/Policies.jsm
mail/components/enterprisepolicies/content/aboutPolicies.js
mail/components/enterprisepolicies/tests/xpcshell/head.js
mail/components/extensions/ExtensionToolbarButtons.jsm
mail/components/extensions/child/ext-menus.js
mail/components/extensions/parent/ext-addressBook.js
mail/components/extensions/parent/ext-mailTabs.js
mail/components/extensions/parent/ext-menus.js
mail/components/extensions/test/browser/browser_ext_compose_attachments.js
mail/components/extensions/test/browser/browser_ext_menus.js
mail/components/extensions/test/browser/head.js
mail/components/extensions/test/xpcshell/head.js
mail/components/im/IMIncomingServer.jsm
mail/components/im/content/addbuddy.js
mail/components/im/content/am-im.js
mail/components/im/content/chat-contact.js
mail/components/im/content/chat-conversation-info.js
mail/components/im/content/chat-conversation.js
mail/components/im/content/chat-imconv.js
mail/components/im/content/chat-messenger.js
mail/components/im/content/imAccountWizard.js
mail/components/im/content/imAccounts.js
mail/components/im/content/imStatusSelector.js
mail/components/im/content/joinchat.js
mail/components/im/modules/ChatEncryption.jsm
mail/components/im/modules/GlodaIMSearcher.jsm
mail/components/im/modules/chatHandler.jsm
mail/components/im/modules/chatNotifications.jsm
mail/components/im/modules/index_im.jsm
mail/components/im/test/TestProtocol.jsm
mail/components/im/test/browser/head.js
mail/components/migration/content/migration.js
mail/components/migration/src/ThunderbirdProfileMigrator.jsm
mail/components/newmailaccount/content/accountProvisioner.js
mail/components/newmailaccount/content/provisionerCheckout.js
mail/components/newmailaccount/content/uriListener.js
mail/components/preferences/attachmentReminder.js
mail/components/preferences/compose.js
mail/components/preferences/connection.js
mail/components/preferences/cookies.js
mail/components/preferences/findInPage.js
mail/components/preferences/fonts.js
mail/components/preferences/general.js
mail/components/preferences/messengerLanguages.js
mail/components/preferences/passwordManager.js
mail/components/preferences/permissions.js
mail/components/preferences/preferences.js
mail/components/preferences/preferencesTab.js
mail/components/prompts/PromptCollection.jsm
mail/components/search/SearchIntegration.jsm
mail/components/test/unit/head_mailcomponents.js
mail/extensions/am-e2e/am-e2e.js
mail/extensions/mailviews/content/mailViewList.js
mail/extensions/openpgp/content/BondOpenPGP.jsm
mail/extensions/openpgp/content/modules/CollectedKeysDB.jsm
mail/extensions/openpgp/content/modules/GPGMELib.jsm
mail/extensions/openpgp/content/modules/OpenPGPAlias.jsm
mail/extensions/openpgp/content/modules/RNP.jsm
mail/extensions/openpgp/content/modules/RNPLib.jsm
mail/extensions/openpgp/content/modules/core.jsm
mail/extensions/openpgp/content/modules/cryptoAPI/GnuPGCryptoAPI.jsm
mail/extensions/openpgp/content/modules/cryptoAPI/RNPCryptoAPI.jsm
mail/extensions/openpgp/content/modules/decryption.jsm
mail/extensions/openpgp/content/modules/dialog.jsm
mail/extensions/openpgp/content/modules/encryption.jsm
mail/extensions/openpgp/content/modules/funcs.jsm
mail/extensions/openpgp/content/modules/keyObj.jsm
mail/extensions/openpgp/content/modules/keyRefreshService.jsm
mail/extensions/openpgp/content/modules/keyRing.jsm
mail/extensions/openpgp/content/modules/keyserver.jsm
mail/extensions/openpgp/content/modules/keyserverUris.jsm
mail/extensions/openpgp/content/modules/log.jsm
mail/extensions/openpgp/content/modules/masterpass.jsm
mail/extensions/openpgp/content/modules/mimeDecrypt.jsm
mail/extensions/openpgp/content/modules/mimeEncrypt.jsm
mail/extensions/openpgp/content/modules/mimeVerify.jsm
mail/extensions/openpgp/content/modules/msgRead.jsm
mail/extensions/openpgp/content/modules/persistentCrypto.jsm
mail/extensions/openpgp/content/modules/pgpmimeHandler.jsm
mail/extensions/openpgp/content/modules/sqliteDb.jsm
mail/extensions/openpgp/content/modules/streams.jsm
mail/extensions/openpgp/content/modules/windows.jsm
mail/extensions/openpgp/content/modules/wksMimeHandler.jsm
mail/extensions/openpgp/content/ui/changeExpiryDlg.js
mail/extensions/openpgp/content/ui/commonWorkflows.js
mail/extensions/openpgp/content/ui/composeKeyStatus.js
mail/extensions/openpgp/content/ui/enigmailCommon.js
mail/extensions/openpgp/content/ui/enigmailKeyManager.js
mail/extensions/openpgp/content/ui/enigmailMessengerOverlay.js
mail/extensions/openpgp/content/ui/enigmailMsgComposeOverlay.js
mail/extensions/openpgp/content/ui/enigmailMsgHdrViewOverlay.js
mail/extensions/openpgp/content/ui/keyAssistant.js
mail/extensions/openpgp/content/ui/keyDetailsDlg.js
mail/extensions/openpgp/content/ui/keyWizard.js
mail/extensions/openpgp/content/ui/oneRecipientStatus.js
mail/extensions/openpgp/test/unit/rnp/test_alias.js
mail/extensions/openpgp/test/unit/rnp/test_badKeys.js
mail/extensions/openpgp/test/unit/rnp/test_uid.js
mail/modules/AppUpdateUI.jsm
mail/modules/ConversationOpener.jsm
mail/modules/DNS.jsm
mail/modules/DisplayNameUtils.jsm
mail/modules/ExtensionSupport.jsm
mail/modules/ExtensionsUI.jsm
mail/modules/GlobalPopupNotifications.jsm
mail/modules/MailE10SUtils.jsm
mail/modules/MailMigrator.jsm
mail/modules/MailUsageTelemetry.jsm
mail/modules/MailUtils.jsm
mail/modules/MessageArchiver.jsm
mail/modules/PhishingDetector.jsm
mail/modules/QuickFilterManager.jsm
mail/modules/SearchSpec.jsm
mail/modules/SessionStoreManager.jsm
mail/modules/TBDistCustomizer.jsm
mail/modules/TagUtils.jsm
mail/modules/UIDensity.jsm
mail/modules/UIFontSize.jsm
mail/modules/WindowsJumpLists.jsm
mail/test/browser/account/browser_abWhitelist.js
mail/test/browser/account/browser_actions.js
mail/test/browser/account/browser_mailAccountSetupWizard.js
mail/test/browser/account/browser_manageIdentities.js
mail/test/browser/account/browser_retestConfig.js
mail/test/browser/account/browser_settingsInfrastructure.js
mail/test/browser/account/browser_values.js
mail/test/browser/attachment/browser_attachment.js
mail/test/browser/attachment/browser_attachmentEvents.js
mail/test/browser/attachment/browser_attachmentInPlainMsg.js
mail/test/browser/cloudfile/browser_attachmentErrors.js
mail/test/browser/cloudfile/browser_attachmentUrls.js
mail/test/browser/cloudfile/browser_notifications.js
mail/test/browser/composition/browser_attachment.js
mail/test/browser/composition/browser_attachmentCloudDraft.js
mail/test/browser/composition/browser_attachmentReminder.js
mail/test/browser/composition/browser_blockedContent.js
mail/test/browser/composition/browser_charsetEdit.js
mail/test/browser/composition/browser_customHeaders.js
mail/test/browser/composition/browser_drafts.js
mail/test/browser/composition/browser_forwardHeaders.js
mail/test/browser/composition/browser_forwardRFC822Attach.js
mail/test/browser/composition/browser_forwardUTF8.js
mail/test/browser/composition/browser_inlineImage.js
mail/test/browser/composition/browser_messageBody.js
mail/test/browser/composition/browser_multipartRelated.js
mail/test/browser/composition/browser_newmsgComposeIdentity.js
mail/test/browser/composition/browser_replyFormatFlowed.js
mail/test/browser/composition/browser_replyMultipartCharset.js
mail/test/browser/composition/browser_replySignature.js
mail/test/browser/composition/browser_saveChangesOnQuit.js
mail/test/browser/composition/browser_signatureInit.js
mail/test/browser/composition/browser_signatureUpdating.js
mail/test/browser/composition/head.js
mail/test/browser/content-policy/browser_generalContentPolicy.js
mail/test/browser/content-policy/browser_pluginsPolicy.js
mail/test/browser/content-tabs/browser_aboutSupport.js
mail/test/browser/content-tabs/browser_contentTab.js
mail/test/browser/content-tabs/browser_installXpi.js
mail/test/browser/downloads/browser_aboutDownloads.js
mail/test/browser/folder-display/browser_columns.js
mail/test/browser/folder-display/browser_messageCommands.js
mail/test/browser/folder-display/browser_paneFocus.js
mail/test/browser/folder-display/browser_viewSource.js
mail/test/browser/folder-widget/browser_messageFilters.js
mail/test/browser/im/browser_toolbarButtons.js
mail/test/browser/keyboard/browser_spacehit.js
mail/test/browser/message-header/browser_messageHeader.js
mail/test/browser/message-header/head.js
mail/test/browser/message-window/browser_emlSubject.js
mail/test/browser/message-window/browser_viewPlaintext.js
mail/test/browser/multiple-identities/browser_displayNames.js
mail/test/browser/newmailaccount/browser_newmailaccount.js
mail/test/browser/notification/browser_notification.js
mail/test/browser/override-main-menu-collapse/browser_overrideMainmenuCollapse.js
mail/test/browser/pref-window/browser_fontChooser.js
mail/test/browser/session-store/browser_sessionStore.js
mail/test/browser/shared-modules/AddressBookHelpers.jsm
mail/test/browser/shared-modules/AttachmentHelpers.jsm
mail/test/browser/shared-modules/CloudfileHelpers.jsm
mail/test/browser/shared-modules/ComposeHelpers.jsm
mail/test/browser/shared-modules/ContentTabHelpers.jsm
mail/test/browser/shared-modules/CustomizationHelpers.jsm
mail/test/browser/shared-modules/EventUtils.jsm
mail/test/browser/shared-modules/FolderDisplayHelpers.jsm
mail/test/browser/shared-modules/MockObjectHelpers.jsm
mail/test/browser/shared-modules/NNTPHelpers.jsm
mail/test/browser/shared-modules/PromptHelpers.jsm
mail/test/browser/shared-modules/WindowHelpers.jsm
mail/test/browser/shared-modules/utils.jsm
mail/test/browser/smime/browser_multipartAlternative.js
mail/test/browser/startup-firstrun/browser_menubarCollapsed.js
mail/test/browser/tabmail/browser_customize.js
mail/test/browser/tabmail/browser_dragndrop.js
mail/test/static/head.js
mail/themes/BuiltInThemes.jsm
mailnews/addrbook/content/abAddressBookNameDialog.js
mailnews/addrbook/content/abCardDAVProperties.js
mailnews/addrbook/content/abMailListDialog.js
mailnews/addrbook/content/map-list.js
mailnews/addrbook/modules/AddrBookCard.jsm
mailnews/addrbook/modules/AddrBookDirectory.jsm
mailnews/addrbook/modules/AddrBookMailingList.jsm
mailnews/addrbook/modules/AddrBookManager.jsm
mailnews/addrbook/modules/AddrBookUtils.jsm
mailnews/addrbook/modules/CardDAVDirectory.jsm
mailnews/addrbook/modules/CardDAVUtils.jsm
mailnews/addrbook/modules/LDAPDirectory.jsm
mailnews/addrbook/modules/LDAPListenerBase.jsm
mailnews/addrbook/modules/LDAPSyncQuery.jsm
mailnews/addrbook/modules/QueryStringToExpression.jsm
mailnews/addrbook/modules/SQLiteDirectory.jsm
mailnews/addrbook/prefs/content/pref-directory-add.js
mailnews/addrbook/prefs/content/pref-editdirectories.js
mailnews/addrbook/src/AbAutoCompleteSearch.jsm
mailnews/addrbook/src/AbLDAPAttributeMap.jsm
mailnews/addrbook/src/AbLDAPAutoCompleteSearch.jsm
mailnews/addrbook/test/LDAPServer.jsm
mailnews/addrbook/test/unit/head.js
mailnews/addrbook/test/unit/head_cardDAV.js
mailnews/addrbook/test/unit/test_LDAPSyncQuery.js
mailnews/addrbook/test/unit/test_convertOnSave.js
mailnews/addrbook/test/unit/test_delete_book.js
mailnews/addrbook/test/unit/test_export.js
mailnews/addrbook/test/unit/test_jsaddrbook.js
mailnews/addrbook/test/unit/test_ldapquery.js
mailnews/addrbook/test/unit/test_nsLDAPURL.js
mailnews/base/content/dateFormat.js
mailnews/base/content/folder-menupopup.js
mailnews/base/content/folderProps.js
mailnews/base/content/junkCommands.js
mailnews/base/content/junkLog.js
mailnews/base/content/menulist-charsetpicker.js
mailnews/base/content/msgAccountCentral.js
mailnews/base/content/msgSynchronize.js
mailnews/base/content/newmailalert.js
mailnews/base/content/virtualFolderProperties.js
mailnews/base/prefs/content/AccountManager.js
mailnews/base/prefs/content/AccountWizard.js
mailnews/base/prefs/content/SmtpServerEdit.js
mailnews/base/prefs/content/accountUtils.js
mailnews/base/prefs/content/am-addressing.js
mailnews/base/prefs/content/am-identities-list.js
mailnews/base/prefs/content/am-identity-edit.js
mailnews/base/prefs/content/am-offline.js
mailnews/base/prefs/content/am-prefs.js
mailnews/base/prefs/content/am-server-advanced.js
mailnews/base/prefs/content/am-server.js
mailnews/base/prefs/content/am-serverwithnoidentities.js
mailnews/base/prefs/content/am-smtp.js
mailnews/base/prefs/content/amUtils.js
mailnews/base/prefs/content/converterDialog.js
mailnews/base/prefs/content/removeAccount.js
mailnews/base/src/ABQueryUtils.jsm
mailnews/base/src/MailAuthenticator.jsm
mailnews/base/src/MailNewsCommandLineHandler.jsm
mailnews/base/src/MailNotificationManager.jsm
mailnews/base/src/MailNotificationService.jsm
mailnews/base/src/MailnewsMigrator.jsm
mailnews/base/src/MsgAsyncPrompter.jsm
mailnews/base/src/MsgDBCacheManager.jsm
mailnews/base/src/MsgIncomingServer.jsm
mailnews/base/src/OAuth2.jsm
mailnews/base/src/OAuth2Module.jsm
mailnews/base/src/TemplateUtils.jsm
mailnews/base/src/WinUnreadBadge.jsm
mailnews/base/src/mailstoreConverter.jsm
mailnews/base/test/unit/head_mailbase.js
mailnews/base/test/unit/test_MsgIncomingServer.js
mailnews/base/test/unit/test_bug434810.js
mailnews/base/test/unit/test_imapPump.js
mailnews/base/test/unit/test_nsMailDirProvider.js
mailnews/base/test/unit/test_testsuite_fakeserver_imapd_gmail.js
mailnews/base/test/unit/test_testsuite_fakeserver_imapd_list-extended.js
mailnews/base/test/unit/test_viewSortByAddresses.js
mailnews/compose/content/sendProgress.js
mailnews/compose/src/MessageSend.jsm
mailnews/compose/src/MimeEncoder.jsm
mailnews/compose/src/MimeMessage.jsm
mailnews/compose/src/MimeMessageUtils.jsm
mailnews/compose/src/MimePart.jsm
mailnews/compose/src/SmtpClient.jsm
mailnews/compose/src/SmtpServer.jsm
mailnews/compose/src/SmtpService.jsm
mailnews/compose/test/unit/head_compose.js
mailnews/compose/test/unit/test_detectAttachmentCharset.js
mailnews/compose/test/unit/test_longLines.js
mailnews/compose/test/unit/test_mailtoURL.js
mailnews/compose/test/unit/test_messageBody.js
mailnews/compose/test/unit/test_messageHeaders.js
mailnews/compose/test/unit/test_nsMsgCompose1.js
mailnews/compose/test/unit/test_sendObserver.js
mailnews/compose/test/unit/test_smtpPassword2.js
mailnews/compose/test/unit/test_smtpPasswordFailure1.js
mailnews/compose/test/unit/test_smtpPasswordFailure2.js
mailnews/compose/test/unit/test_smtpPasswordFailure3.js
mailnews/compose/test/unit/test_smtpProtocols.js
mailnews/compose/test/unit/test_smtpServer.js
mailnews/compose/test/unit/test_staleTemporaryFileCleanup.js
mailnews/compose/test/unit/test_temporaryFilesRemoved.js
mailnews/db/gloda/content/autocomplete-richlistitem.js
mailnews/db/gloda/modules/GlodaDatastore.jsm
mailnews/db/gloda/modules/GlodaExplicitAttr.jsm
mailnews/db/gloda/modules/GlodaFundAttr.jsm
mailnews/db/gloda/modules/GlodaIndexer.jsm
mailnews/db/gloda/modules/GlodaMsgIndexer.jsm
mailnews/db/gloda/modules/GlodaMsgSearcher.jsm
mailnews/db/gloda/modules/GlodaSyntheticView.jsm
mailnews/db/gloda/modules/IndexMsg.jsm
mailnews/db/gloda/modules/MimeMessage.jsm
mailnews/db/gloda/modules/NounMimetype.jsm
mailnews/db/gloda/test/unit/base_index_junk.js
mailnews/db/gloda/test/unit/base_index_messages.js
mailnews/db/gloda/test/unit/resources/GlodaTestHelper.jsm
mailnews/db/gloda/test/unit/test_corrupt_database.js
mailnews/db/gloda/test/unit/test_index_compaction.js
mailnews/db/gloda/test/unit/test_index_junk_imap_offline.js
mailnews/db/gloda/test/unit/test_index_sweep_folder.js
mailnews/db/gloda/test/unit/test_mime_attachments_size.js
mailnews/db/gloda/test/unit/test_msg_search.js
mailnews/db/gloda/test/unit/test_nuke_migration.js
mailnews/db/gloda/test/unit/test_query_messages_imap_offline.js
mailnews/db/gloda/test/unit/test_query_messages_imap_online.js
mailnews/db/gloda/test/unit/test_query_messages_imap_online_to_offline.js
mailnews/db/gloda/test/unit/test_query_messages_local.js
mailnews/db/gloda/test/unit/test_startup_offline.js
mailnews/db/msgdb/test/unit/head_maildb.js
mailnews/export/content/exportDialog.js
mailnews/export/modules/ProfileExporter.jsm
mailnews/extensions/bayesian-spam-filter/test/unit/head_bayes.js
mailnews/extensions/bayesian-spam-filter/test/unit/resources/trainingfile.js
mailnews/extensions/mdn/am-mdn.js
mailnews/extensions/mdn/test/unit/head_mdn.js
mailnews/extensions/newsblog/Feed.jsm
mailnews/extensions/newsblog/FeedItem.jsm
mailnews/extensions/newsblog/FeedParser.jsm
mailnews/extensions/newsblog/FeedUtils.jsm
mailnews/extensions/newsblog/feed-subscriptions.js
mailnews/extensions/newsblog/newsblogOverlay.js
mailnews/extensions/newsblog/test/unit/head_feeds.js
mailnews/extensions/offline-startup/OfflineStartup.jsm
mailnews/extensions/smime/certFetchingStatus.js
mailnews/extensions/smime/msgCompSecurityInfo.js
mailnews/extensions/smime/msgReadSMIMEOverlay.js
mailnews/imap/src/ImapClient.jsm
mailnews/imap/src/ImapMessageService.jsm
mailnews/imap/src/ImapModuleLoader.jsm
mailnews/imap/src/ImapService.jsm
mailnews/imap/test/unit/head_server.js
mailnews/imap/test/unit/test_customCommandReturnsFetchResponse.js
mailnews/imap/test/unit/test_dod.js
mailnews/imap/test/unit/test_fetchCustomAttribute.js
mailnews/imap/test/unit/test_filterCustomHeaders.js
mailnews/imap/test/unit/test_gmailAttributes.js
mailnews/imap/test/unit/test_gmailOfflineMsgStore.js
mailnews/imap/test/unit/test_imapHdrChunking.js
mailnews/imap/test/unit/test_imapHighWater.js
mailnews/imap/test/unit/test_imapMove.js
mailnews/imap/test/unit/test_imapPasswordFailure.js
mailnews/imap/test/unit/test_imapProtocols.js
mailnews/imap/test/unit/test_imapRename.js
mailnews/imap/test/unit/test_listSubscribed.js
mailnews/imap/test/unit/test_lsub.js
mailnews/imap/test/unit/test_offlineDraftDataloss.js
mailnews/imap/test/unit/test_partsOnDemand.js
mailnews/imap/test/unit/test_saveImapDraft.js
mailnews/imap/test/unit/test_saveTemplate.js
mailnews/imap/test/unit/test_starttlsFailure.js
mailnews/imap/test/unit/test_stopMovingToLocalFolder.js
mailnews/import/content/aboutImport.js
mailnews/import/content/csv-field-map.js
mailnews/import/content/importDialog.js
mailnews/import/modules/AddrBookFileImporter.jsm
mailnews/import/modules/BaseProfileImporter.jsm
mailnews/import/modules/CalendarFileImporter.jsm
mailnews/import/modules/SeamonkeyProfileImporter.jsm
mailnews/import/modules/ThunderbirdProfileImporter.jsm
mailnews/import/src/SeamonkeyImport.jsm
mailnews/import/test/unit/head_import.js
mailnews/import/test/unit/test_ThunderbirdProfileImporter.js
mailnews/jsaccount/test/unit/head_jsaccount.js
mailnews/jsaccount/test/unit/resources/TestJaMsgProtocolInfoComponent.jsm
mailnews/local/src/Pop3Client.jsm
mailnews/local/src/Pop3ModuleLoader.jsm
mailnews/local/src/Pop3ProtocolInfo.jsm
mailnews/local/test/unit/head_maillocal.js
mailnews/local/test/unit/test_mailboxProtocol.js
mailnews/mapi/test/unit/head_mapi.js
mailnews/mapi/test/unit/test_mapisendmail.js
mailnews/mime/jsmime/test/unit/head_xpcshell_glue.js
mailnews/mime/src/jsmime.jsm
mailnews/mime/test/unit/head_mime.js
mailnews/mime/test/unit/test_attachment_size.js
mailnews/mime/test/unit/test_structured_headers.js
mailnews/news/src/NntpChannel.jsm
mailnews/news/src/NntpClient.jsm
mailnews/news/src/NntpIncomingServer.jsm
mailnews/news/src/NntpMessageService.jsm
mailnews/news/src/NntpModuleLoader.jsm
mailnews/news/src/NntpNewsGroup.jsm
mailnews/news/src/NntpProtocolInfo.jsm
mailnews/news/src/NntpService.jsm
mailnews/news/src/NntpUtils.jsm
mailnews/news/test/unit/head_server_setup.js
mailnews/news/test/unit/test_nntpPassword3.js
mailnews/news/test/unit/test_nntpPasswordFailure.js
mailnews/news/test/unit/test_nntpProtocols.js
mailnews/news/test/unit/test_nntpUrl.js
mailnews/news/test/unit/test_uriParser.js
mailnews/search/content/CustomHeaders.js
mailnews/search/content/FilterEditor.js
mailnews/search/content/searchWidgets.js
mailnews/search/src/MsgTraitService.jsm
mailnews/search/src/PeriodicFilterManager.jsm
mailnews/search/test/unit/head_mailbase.js
mailnews/search/test/unit/test_searchLocalizationStrings.js
mailnews/test/fakeserver/Binaryd.jsm
mailnews/test/fakeserver/Imapd.jsm
mailnews/test/fakeserver/Maild.jsm
mailnews/test/fakeserver/Pop3d.jsm
mailnews/test/resources/IMAPpump.jsm
mailnews/test/resources/LocalAccountUtils.jsm
mailnews/test/resources/MailTestUtils.jsm
mailnews/test/resources/MessageInjection.jsm
mailnews/test/resources/NetworkTestUtils.jsm
mailnews/test/resources/POP3pump.js
mailnews/test/resources/abSetup.js
mailnews/test/resources/alertTestUtils.js
mailnews/test/resources/logHelper.js
mailnews/test/resources/mailShutdown.js
mailnews/test/resources/passwordStorage.js
--- a/calendar/base/backend/CalBackendLoader.jsm
+++ b/calendar/base/backend/CalBackendLoader.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalBackendLoader"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 function CalBackendLoader() {
   try {
     this.loadBackend();
   } catch (e) {
     dump(`### Error loading backend:${e.filename || e.fileName}:${e.lineNumber}: ${e}\n`);
   }
 }
 
--- a/calendar/base/backend/icaljs/calICALJSComponents.js
+++ b/calendar/base/backend/icaljs/calICALJSComponents.js
@@ -5,17 +5,16 @@
 /* import-globals-from ../../src/calTimezone.js */
 /* import-globals-from calDateTime.js */
 /* import-globals-from calDuration.js */
 /* import-globals-from calICSService.js */
 /* import-globals-from calPeriod.js */
 /* import-globals-from calRecurrenceRule.js */
 
 var { ComponentUtils } = ChromeUtils.import("resource://gre/modules/ComponentUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * @param {string} cid - Class ID as string.
  * @returns {function} Constructor to create the requested class ID component.
  */
 this.getComponentConstructor = cid => {
   if (!this.loadedScripts) {
     let scriptLoadOrder = [
--- a/calendar/base/content/calendar-chrome-startup.js
+++ b/calendar/base/content/calendar-chrome-startup.js
@@ -10,17 +10,16 @@
    observeViewDaySelect, getViewBox, calendarController, calendarUpdateNewItemsCommand,
    TodayPane, setUpInvitationsManager, changeMode, MailToolboxCustomizeDone,
    prepareCalendarUnifinder, taskViewOnLoad, taskEdit, tearDownInvitationsManager,
    unloadCalendarManager, removeCalendarCommandController, finishCalendarUnifinder,
    PanelUI, changeMenuForTask, setupDeleteMenuitem, getMinimonth, currentView,
    refreshEventTree, gCurrentMode, InitMessageMenu, onViewToolbarsPopupShowing,
    onCommandCustomize, CustomizeMailToolbar */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AddonManager } = ChromeUtils.import("resource://gre/modules/AddonManager.jsm");
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { calendarDeactivator } = ChromeUtils.import(
   "resource:///modules/calendar/calCalendarDeactivator.jsm"
 );
 
 ChromeUtils.defineModuleGetter(this, "CalMetronome", "resource:///modules/CalMetronome.jsm");
--- a/calendar/base/content/calendar-clipboard.js
+++ b/calendar/base/content/calendar-clipboard.js
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* globals getSelectedCalendar, getSelectedItems, promptOccurrenceModification,
    calendarViewController, currentView, startBatchTransaction, doTransaction,
    endBatchTransaction */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 /* exported cutToClipboard, pasteFromClipboard */
 
 /**
  * Test if a writable calendar is selected, and if the clipboard has items that
  * can be pasted into Calendar. The data must be of type "text/calendar" or
  * "text/unicode".
--- a/calendar/base/content/calendar-command-controller.js
+++ b/calendar/base/content/calendar-command-controller.js
@@ -8,17 +8,16 @@
    createTodoWithDialog, deleteToDoCommand, promptDeleteCalendar,
    toImport, loadEventsFromFile, exportEntireCalendar, saveEventsToFile,
    publishEntireCalendar, publishCalendarData, toggleUnifinder, toggleOrientation
    toggleWorkdaysOnly, switchCalendarView, getTaskTree, selectAllEvents,
    gCurrentMode, getSelectedTasks, canPaste, goSetMenuValue, canUndo, canRedo,
    cutToClipboard, copyToClipboard, pasteFromClipboard, undo, redo,
    setupAttendanceMenu, goUpdateCommand, PrintUtils */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 var CalendarDeleteCommandEnabled = false;
 var CalendarNewEventsCommandEnabled = false;
 var CalendarNewTasksCommandEnabled = false;
 
 /**
  * Command controller to execute calendar specific commands
--- a/calendar/base/content/calendar-dnd-listener.js
+++ b/calendar/base/content/calendar-dnd-listener.js
@@ -13,17 +13,16 @@
 var calendarViewDNDObserver;
 var calendarMailButtonDNDObserver;
 var calendarCalendarButtonDNDObserver;
 var calendarTaskButtonDNDObserver;
 
 // Wrap in a block to prevent leaking to window scope.
 {
   var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-  var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
   var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
   var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
   XPCOMUtils.defineLazyModuleGetters(this, {
     CalAttachment: "resource:///modules/CalAttachment.jsm",
     CalAttendee: "resource:///modules/CalAttendee.jsm",
     CalEvent: "resource:///modules/CalEvent.jsm",
--- a/calendar/base/content/calendar-editable-item.js
+++ b/calendar/base/content/calendar-editable-item.js
@@ -4,17 +4,16 @@
 
 /* global MozElements, MozXULElement, onMouseOverItem, invokeEventDragSession */
 
 "use strict";
 
 // Wrap in a block to prevent leaking to window scope.
 {
   var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-  var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   /**
    * The MozCalendarEditableItem widget is used as a full day event item in the
    * Day and Week views of the calendar. It displays the event name, alarm icon
    * and the category type color. It gets displayed in the header container of
    * the respective view of the calendar.
    *
    * @extends MozXULElement
    */
--- a/calendar/base/content/calendar-extract.js
+++ b/calendar/base/content/calendar-extract.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* globals getMessagePaneBrowser, gFolderDisplay, addMenuItem, getSelectedCalendar
    createEventWithDialog*/
 
 var { Extractor } = ChromeUtils.import("resource:///modules/calendar/calExtract.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalEvent: "resource:///modules/CalEvent.jsm",
   CalTodo: "resource:///modules/CalTodo.jsm",
 });
 
 XPCOMUtils.defineLazyGetter(this, "extractService", () => {
--- a/calendar/base/content/calendar-invitations-manager.js
+++ b/calendar/base/content/calendar-invitations-manager.js
@@ -1,14 +1,13 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var { CalReadableStreamFactory } = ChromeUtils.import(
   "resource:///modules/CalReadableStreamFactory.jsm"
 );
 
 /* exported getInvitationsManager, openInvitationsDialog, setUpInvitationsManager,
  *          tearDownInvitationsManager
  */
--- a/calendar/base/content/calendar-management.js
+++ b/calendar/base/content/calendar-management.js
@@ -6,17 +6,16 @@
 
 /* exported promptDeleteCalendar, loadCalendarManager, unloadCalendarManager,
  *   calendarListTooltipShowing, calendarListSetupContextMenu,
  *   ensureCalendarVisible, toggleCalendarVisible, showAllCalendars,
  *   showOnlyCalendar, calendarOfflineManager, openLocalCalendar,
  */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 // Temporary bundle for 78 to get the "Enable" string from the addons.properties file.
 var bundle;
 
 /**
  * Get this window's currently selected calendar.
  *
  * @return      The currently selected calendar.
--- a/calendar/base/content/calendar-migration.js
+++ b/calendar/base/content/calendar-migration.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* globals MODE_RDONLY, putItemsIntoCal*/
 
 var FIREFOX_UID = "{ec8030f7-c20a-464f-9b0e-13a3a9e97384}";
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 
 /**
  * A data migrator prototype, holding the information for migration
  *
  * @class
  * @param aTitle    The title of the migrator
  * @param aMigrateFunction    The function to call when migrating
--- a/calendar/base/content/calendar-task-tree.js
+++ b/calendar/base/content/calendar-task-tree.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* globals MozXULElement, calendarController, invokeEventDragSession, CalendarTaskTreeView,
     calFilter, TodayPane, currentView */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
   const { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
 
   /**
    * An observer for the calendar event data source. This keeps the unifinder
    * display up to date when the calendar event data is changed.
    *
    * @implements {calIObserver}
--- a/calendar/base/content/calendar-task-view.js
+++ b/calendar/base/content/calendar-task-view.js
@@ -7,17 +7,16 @@
 /* import-globals-from ../../../mail/base/content/mailCore.js */
 /* import-globals-from item-editing/calendar-item-editing.js */
 /* import-globals-from calendar-ui-utils.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { recurrenceRule2String } = ChromeUtils.import(
   "resource:///modules/calendar/calRecurrenceUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 
 var taskDetailsView = {
   /**
    * Task Details Events
    *
    * XXXberend Please document this function, possibly also consolidate since
    * its the only function in taskDetailsView.
--- a/calendar/base/content/calendar-ui-utils.js
+++ b/calendar/base/content/calendar-ui-utils.js
@@ -10,17 +10,16 @@
  *          getOptimalMinimumWidth, getOptimalMinimumHeight,
  *          setupAttendanceMenu
  */
 
 /* import-globals-from ../../../../toolkit/content/globalOverlay.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 /**
  * This function unconditionally disables the element for
  * which the id has been passed as argument. Furthermore, it
  * remembers who was responsible for this action by using
  * the given key (lockId). In case the control should be
  * enabled again the lock gets removed, but the control only
--- a/calendar/base/content/calendar-unifinder.js
+++ b/calendar/base/content/calendar-unifinder.js
@@ -17,17 +17,16 @@
  * This is a hacked in interface to the unifinder. We will need to
  * improve this to make it usable in general.
  *
  * NOTE: Including this file will cause a load handler to be added to the
  * window.
  */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 // Set this to true when the calendar event tree is clicked to allow for
 // multiple selection
 var gCalendarEventTreeClicked = false;
 
 // Store the start and enddate, because the providers can't be trusted when
 // dealing with all-day events. So we need to filter later. See bug 306157
 
--- a/calendar/base/content/calendar-views-utils.js
+++ b/calendar/base/content/calendar-views-utils.js
@@ -11,17 +11,16 @@
 
 /* import-globals-from item-editing/calendar-item-editing.js */
 /* import-globals-from calendar-modes.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { countOccurrences } = ChromeUtils.import(
   "resource:///modules/calendar/calRecurrenceUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalEvent: "resource:///modules/CalEvent.jsm",
 });
 
 /**
  * Controller for the views
--- a/calendar/base/content/calendar-views.js
+++ b/calendar/base/content/calendar-views.js
@@ -14,17 +14,16 @@
 //                                     /               \
 //             CalendarMultidayBaseView                CalendarMonthBaseView
 //                 /           \                           /               \
 //     CalendarDayView     CalendarWeekView    CalendarMultiweekView    CalendarMonthView
 
 // Wrap in a block to prevent leaking to window scope.
 {
   var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-  var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
   /**
    * The calendar view for viewing a single day.
    *
    * @extends {MozElements.CalendarMultidayBaseView}
    * @implements {calICalendarView}
    */
   class CalendarDayView extends MozElements.CalendarMultidayBaseView {
--- a/calendar/base/content/dialogs/calendar-alarm-dialog.js
+++ b/calendar/base/content/dialogs/calendar-alarm-dialog.js
@@ -7,17 +7,16 @@
  */
 
 /* global MozElements */
 
 /* import-globals-from ../item-editing/calendar-item-editing.js */
 
 var { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 window.addEventListener("load", event => {
   setupWindow();
   window.arguments[0].wrappedJSObject.window_onLoad();
 });
 window.addEventListener("unload", finishWindow);
 window.addEventListener("focus", onFocusWindow);
--- a/calendar/base/content/dialogs/calendar-creation.js
+++ b/calendar/base/content/dialogs/calendar-creation.js
@@ -1,14 +1,13 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ExtensionParent } = ChromeUtils.import("resource://gre/modules/ExtensionParent.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 ChromeUtils.defineModuleGetter(this, "MsgAuthPrompt", "resource:///modules/MsgAsyncPrompter.jsm");
 
 /* exported checkRequired, fillLocationPlaceholder, selectProvider, updateNoCredentials, */
 
 /* import-globals-from calendar-identity-utils.js */
--- a/calendar/base/content/dialogs/calendar-dialog-utils.js
+++ b/calendar/base/content/dialogs/calendar-dialog-utils.js
@@ -7,18 +7,16 @@
  *          commonUpdateReminder, updateLink,
  *          adaptScheduleAgent, sendMailToOrganizer,
  *          openAttachmentFromItemSummary,
  */
 
 /* import-globals-from ../item-editing/calendar-item-iframe.js */
 /* import-globals-from ../calendar-ui-utils.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAlarm: "resource:///modules/CalAlarm.jsm",
 });
 
 // Variables related to whether we are in a tab or a window dialog.
--- a/calendar/base/content/dialogs/calendar-event-dialog-attendees.js
+++ b/calendar/base/content/dialogs/calendar-event-dialog-attendees.js
@@ -3,17 +3,16 @@
  * file, you can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* global MozXULElement */
 /* import-globals-from ../calendar-ui-utils.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
 var { MailUtils } = ChromeUtils.import("resource:///modules/MailUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAttendee: "resource:///modules/CalAttendee.jsm",
 });
 
 var readOnly = false;
 
--- a/calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
+++ b/calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
@@ -5,17 +5,16 @@
 /* exported onLoad */
 
 /* import-globals-from ../calendar-ui-utils.js */
 
 var { splitRecurrenceRules } = ChromeUtils.import(
   "resource:///modules/calendar/calRecurrenceUtils.jsm"
 );
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalRecurrenceInfo: "resource:///modules/CalRecurrenceInfo.jsm",
 });
 
 var gIsReadOnly = false;
 var gStartTime = null;
--- a/calendar/base/content/dialogs/calendar-event-dialog-reminder.js
+++ b/calendar/base/content/dialogs/calendar-event-dialog-reminder.js
@@ -4,17 +4,16 @@
 
 /* exported onLoad, onReminderSelected, updateReminder, onNewReminder, onRemoveReminder */
 
 /* global MozElements */
 
 /* import-globals-from ../calendar-ui-utils.js */
 
 var { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAlarm: "resource:///modules/CalAlarm.jsm",
 });
 
 var allowedActionsMap = {};
--- a/calendar/base/content/dialogs/calendar-ics-file-dialog.js
+++ b/calendar/base/content/dialogs/calendar-ics-file-dialog.js
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* globals addMenuItem, getItemsFromIcsFile, putItemsIntoCal,
            sortCalendarArray */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 const gModel = {
   /** @type {calICalendar[]} */
   calendars: [],
 
   /** @type {Map(number -> calIItemBase)} */
   itemsToImport: new Map(),
 
--- a/calendar/base/content/dialogs/calendar-invitations-dialog.js
+++ b/calendar/base/content/dialogs/calendar-invitations-dialog.js
@@ -3,18 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* globals MozXULElement, MozElements */ // From calendar-invitations-dialog.xhtml.
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
   class MozCalendarInvitationsRichlistitem extends MozElements.MozRichlistitem {
     constructor() {
       super();
 
       this.mCalendarItem = null;
       this.mInitialParticipationStatus = null;
       this.mParticipationStatus = null;
       this.calInvitationsProps = Services.strings.createBundle(
--- a/calendar/base/content/dialogs/calendar-migration-dialog.js
+++ b/calendar/base/content/dialogs/calendar-migration-dialog.js
@@ -1,14 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var gMigrateWizard = {
   /**
    * Called from onload of the migrator window.  Takes all of the migrators
    * that were passed in via window.arguments and adds them to checklist. The
    * user can then check these off to migrate the data from those sources.
    */
   loadMigrators() {
     let wizardPage2 = document.getElementById("wizardPage2");
--- a/calendar/base/content/imip-bar.js
+++ b/calendar/base/content/imip-bar.js
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* import-globals-from ../../../mail/base/content/msgHdrView.js */
 /* import-globals-from item-editing/calendar-item-editing.js */
 
 /* globals gMessageDisplay, msgWindow */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * Provides shortcuts to set label and collapsed attribute of imip-bar node.
  */
 const imipBar = {
   get bar() {
     return document.querySelector(".calendar-notification-bar");
   },
--- a/calendar/base/content/import-export.js
+++ b/calendar/base/content/import-export.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from item-editing/calendar-item-editing.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 /* exported loadEventsFromFile, exportEntireCalendar */
 
 // File constants copied from file-utils.js
 var MODE_RDONLY = 0x01;
 var MODE_WRONLY = 0x02;
 var MODE_CREATE = 0x08;
--- a/calendar/base/content/item-editing/calendar-item-editing.js
+++ b/calendar/base/content/item-editing/calendar-item-editing.js
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* import-globals-from ../calendar-management.js */
 /* import-globals-from ../calendar-views-utils.js */
 
 /* globals goUpdateCommand */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 var { CalTransactionManager } = ChromeUtils.import("resource:///modules/CalTransactionManager.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAddTransaction: "resource:///modules/CalTransactionManager.jsm",
   CalDeleteTransaction: "resource:///modules/CalTransactionManager.jsm",
   CalEvent: "resource:///modules/CalEvent.jsm",
   CalModifyTransaction: "resource:///modules/CalTransactionManager.jsm",
--- a/calendar/base/content/item-editing/calendar-item-iframe.js
+++ b/calendar/base/content/item-editing/calendar-item-iframe.js
@@ -18,17 +18,16 @@
 
 /* import-globals-from ../../../../mail/components/compose/content/editor.js */
 /* import-globals-from ../../../../mail/components/compose/content/editorUtilities.js */
 /* import-globals-from ../calendar-ui-utils.js */
 /* import-globals-from ../dialogs/calendar-dialog-utils.js */
 /* globals gTimezonesEnabled */ // Set by calendar-item-panel.js.
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var {
   recurrenceRule2String,
   splitRecurrenceRules,
   checkRecurrenceRule,
   countOccurrences,
   hasUnsupported,
 } = ChromeUtils.import("resource:///modules/calendar/calRecurrenceUtils.jsm");
 var { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
--- a/calendar/base/content/item-editing/calendar-item-panel.js
+++ b/calendar/base/content/item-editing/calendar-item-panel.js
@@ -12,17 +12,16 @@
  */
 
 /* import-globals-from ../../../../../toolkit/content/globalOverlay.js */
 /* import-globals-from ../dialogs/calendar-dialog-utils.js */
 /* import-globals-from ../calendar-ui-utils.js */
 
 // XXX Need to determine which of these we really need here.
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
 
 // gTabmail is null if we are in a dialog window and not in a tab.
 var gTabmail = document.getElementById("tabmail") || null;
 
 if (!gTabmail) {
   // In a dialog window the following menu item functions need to be
   // defined.  In a tab they are defined elsewhere.  To prevent errors in
--- a/calendar/base/content/preferences/alarms.js
+++ b/calendar/base/content/preferences/alarms.js
@@ -2,18 +2,16 @@
  * 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/. */
 
 /* exported gAlarmsPane */
 
 /* import-globals-from ../calendar-ui-utils.js */
 /* globals Preferences */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 Preferences.addAll([
   { id: "calendar.alarms.playsound", type: "bool" },
   { id: "calendar.alarms.soundURL", type: "string" },
   { id: "calendar.alarms.soundType", type: "int" },
   { id: "calendar.alarms.show", type: "bool" },
   { id: "calendar.alarms.showmissed", type: "bool" },
   { id: "calendar.alarms.onforevents", type: "int" },
   { id: "calendar.alarms.onfortodos", type: "int" },
--- a/calendar/base/content/preferences/categories.js
+++ b/calendar/base/content/preferences/categories.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* exported gCategoriesPane */
 
 /* globals gSubDialog, Preferences */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 
 Preferences.add({ id: "calendar.categories.names", type: "string" });
 
 var gCategoryList;
 var categoryPrefBranch = Services.prefs.getBranch("calendar.category.color.");
 
 /**
--- a/calendar/base/content/publish.js
+++ b/calendar/base/content/publish.js
@@ -4,17 +4,16 @@
 
 /* exported publishCalendarData, publishCalendarDataDialogResponse,
  *          publishEntireCalendar, publishEntireCalendarDialogResponse
  */
 
 /* import-globals-from ../../base/content/calendar-views-utils.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * publishCalendarData
  * Show publish dialog, ask for URL and publish all selected items.
  */
 function publishCalendarData() {
   let args = {};
 
--- a/calendar/base/content/today-pane.js
+++ b/calendar/base/content/today-pane.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from calendar-modes.js */
 /* import-globals-from calendar-tabs.js */
 /* import-globals-from calendar-views-utils.js */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * Namespace object to hold functions related to the today pane.
  */
 var TodayPane = {
   isLoaded: false,
   paneViews: null,
   start: null,
--- a/calendar/base/content/widgets/calendar-filter.js
+++ b/calendar/base/content/widgets/calendar-filter.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from ../calendar-views-utils.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { PromiseUtils } = ChromeUtils.import("resource://gre/modules/PromiseUtils.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { CalReadableStreamFactory } = ChromeUtils.import(
   "resource:///modules/CalReadableStreamFactory.jsm"
 );
 
 /**
  * Object that contains a set of filter properties that may be used by a calFilter object
--- a/calendar/base/content/widgets/calendar-minimonth.js
+++ b/calendar/base/content/widgets/calendar-minimonth.js
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* globals cal MozXULElement */
 
 "use strict";
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   const { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
   /**
    * MiniMonth Calendar: day-of-month grid component.
    * Displays month name and year above grid of days of month by week rows.
    * Arrows move forward or back a month or a year.
    * Clicking on a day cell selects that day.
    * At site, can provide id, and code to run when value changed by picker.
--- a/calendar/base/content/widgets/calendar-modebox.js
+++ b/calendar/base/content/widgets/calendar-modebox.js
@@ -3,18 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 "use strict";
 
 /* globals MozXULElement */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  let { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
   /**
    * A calendar-modebox directly extends to a xul:box element with extra functionality. Like a
    * xul:hbox it has a horizontal orientation. It is designed to be displayed only:
    * 1) in given application modes (e.g "task" mode, "calendar" mode) and
    * 2) only in relation to the "checked" attribute of a control (e.g. a command or checkbox).
    *
    * - The attribute "mode" denotes a comma-separated list of all modes that the modebox should
    *   not be collapsed in, e.g. `mode="calendar,task"`.
--- a/calendar/base/content/widgets/datetimepickers.js
+++ b/calendar/base/content/widgets/datetimepickers.js
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* global MozElements, MozXULElement */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
   // Leave these first arguments as `undefined`, to use the OS style if
   // intl.regional_prefs.use_os_locales is true or the app language matches the OS language.
   // Otherwise, the app language is used.
   let dateFormatter = new Services.intl.DateTimeFormat(undefined, { dateStyle: "short" });
   let timeFormatter = new Services.intl.DateTimeFormat(undefined, { timeStyle: "short" });
 
--- a/calendar/base/modules/calCalendarDeactivator.jsm
+++ b/calendar/base/modules/calCalendarDeactivator.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["calendarDeactivator"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 /**
  * Handles deactivation of calendar UI and background processes/services (such
  * as the alarms service) when users do not want to use calendar functionality.
  * Also handles re-activation when users change their mind.
  *
  * If all of a user's calendars are disabled (e.g. calendar > properties >
--- a/calendar/base/modules/calExtract.jsm
+++ b/calendar/base/modules/calExtract.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["Extractor"];
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * Initializes extraction
  *
  * @param fallbackLocale  locale to use when others are not found or
  *                            detection is disabled
  * @param dayStart        ambiguous hours earlier than this are considered to
  *                            be in the afternoon, when null then by default
--- a/calendar/base/modules/calUtils.jsm
+++ b/calendar/base/modules/calUtils.jsm
@@ -1,14 +1,13 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ConsoleAPI } = ChromeUtils.import("resource://gre/modules/Console.jsm");
 
 // Usually the backend loader gets loaded via profile-after-change, but in case
 // a calendar component hooks in earlier, its very likely it will use calUtils.
 // Getting the service here will load if its not already loaded
 Cc["@mozilla.org/calendar/backend-loader;1"].getService();
 
 // The calendar console instance
--- a/calendar/base/modules/utils/calACLUtils.jsm
+++ b/calendar/base/modules/utils/calACLUtils.jsm
@@ -6,18 +6,16 @@
  * Helpers for permission checks and other ACL features
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.acl namespace.
 
 const EXPORTED_SYMBOLS = ["calacl"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var calacl = {
   /**
    * Check if the specified calendar is writable. This is the case when it is
    * not marked readOnly, we are not offline, or we are offline and the
    * calendar is local.
    *
    * @param aCalendar     The calendar to check
    * @return              True if the calendar is writable
--- a/calendar/base/modules/utils/calAlarmUtils.jsm
+++ b/calendar/base/modules/utils/calAlarmUtils.jsm
@@ -6,17 +6,16 @@
  * Helpers for manipulating calendar alarms
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.alarm namespace.
 
 const EXPORTED_SYMBOLS = ["calalarms"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 XPCOMUtils.defineLazyModuleGetters(lazy, {
   CalAlarm: "resource:///modules/CalAlarm.jsm",
 });
--- a/calendar/base/modules/utils/calAuthUtils.jsm
+++ b/calendar/base/modules/utils/calAuthUtils.jsm
@@ -6,17 +6,16 @@
  * Authentication tools and prompts, mostly for providers
  */
 
 // NOTE: This module should not be loaded directly, it is available when including
 // calUtils.jsm under the cal.auth namespace.
 
 const EXPORTED_SYMBOLS = ["calauth"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 
 XPCOMUtils.defineLazyModuleGetters(lazy, {
   cal: "resource:///modules/calendar/calUtils.jsm",
   MsgAuthPrompt: "resource:///modules/MsgAsyncPrompter.jsm",
   setTimeout: "resource://gre/modules/Timer.jsm",
--- a/calendar/base/modules/utils/calCategoryUtils.jsm
+++ b/calendar/base/modules/utils/calCategoryUtils.jsm
@@ -6,18 +6,16 @@
  * Helpers for reading and writing calendar categories
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.category namespace.
 
 const EXPORTED_SYMBOLS = ["calcategory"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 
 var calcategory = {
   /**
    * Sets up the default categories from the localized string
    *
    * @return      The default set of categories as a comma separated string.
--- a/calendar/base/modules/utils/calDateTimeFormatter.jsm
+++ b/calendar/base/modules/utils/calDateTimeFormatter.jsm
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 
 XPCOMUtils.defineLazyGetter(lazy, "gDateStringBundle", () =>
   Services.strings.createBundle("chrome://calendar/locale/dateFormat.properties")
--- a/calendar/base/modules/utils/calDateTimeUtils.jsm
+++ b/calendar/base/modules/utils/calDateTimeUtils.jsm
@@ -6,18 +6,16 @@
  * Date, time and timezone related functions
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.dtz namespace.
 
 const EXPORTED_SYMBOLS = ["caldtz"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 
 var caldtz = {
   /**
    * Shortcut to the timezone service's defaultTimezone
    */
   get defaultTimezone() {
--- a/calendar/base/modules/utils/calItemUtils.jsm
+++ b/calendar/base/modules/utils/calItemUtils.jsm
@@ -1,14 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calHashedArray.jsm");
 
 /*
  * Calendar item related functions
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.item namespace.
--- a/calendar/base/modules/utils/calIteratorUtils.jsm
+++ b/calendar/base/modules/utils/calIteratorUtils.jsm
@@ -6,18 +6,16 @@
  * Iterators for various data structures
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.iterate namespace.
 
 const EXPORTED_SYMBOLS = ["caliterate"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 
 var caliterate = {
   /**
    * Iterates an array of items, i.e. the passed item including all
    * overridden instances of a recurring series.
    *
--- a/calendar/base/modules/utils/calItipUtils.jsm
+++ b/calendar/base/modules/utils/calItipUtils.jsm
@@ -6,17 +6,16 @@
  * Scheduling and iTIP helper code
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.itip namespace.
 
 const EXPORTED_SYMBOLS = ["calitip"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
 var { calendarDeactivator } = ChromeUtils.import(
   "resource:///modules/calendar/calCalendarDeactivator.jsm"
 );
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 XPCOMUtils.defineLazyModuleGetters(lazy, {
--- a/calendar/base/modules/utils/calL10NUtils.jsm
+++ b/calendar/base/modules/utils/calL10NUtils.jsm
@@ -6,18 +6,16 @@
  * Localization and locale functions
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.l10n namespace.
 
 const EXPORTED_SYMBOLS = ["call10n"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 /**
  * Gets the value of a string in a .properties file.
  *
  * @param {String} aComponent       Stringbundle component name
  * @param {String} aBundleName      The name of the properties file
  * @param {String} aStringName      The name of the string within the properties file
  * @param {String[]} aParams        (optional) Parameters to format the string
  * @return {String}                 The formatted string
--- a/calendar/base/modules/utils/calPrintUtils.jsm
+++ b/calendar/base/modules/utils/calPrintUtils.jsm
@@ -12,18 +12,16 @@
  * by the user.
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.print namespace.
 
 const EXPORTED_SYMBOLS = ["calprint"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 
 var calprint = {
   ensureInitialized() {
     // Deliberate no-op. By calling this function from outside, you've ensured
     // the observer has been added.
   },
--- a/calendar/base/modules/utils/calProviderDetectionUtils.jsm
+++ b/calendar/base/modules/utils/calProviderDetectionUtils.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["calproviderdetection"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 /**
  * Code to call the calendar provider detection mechanism.
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.provider.detection namespace.
--- a/calendar/base/modules/utils/calProviderUtils.jsm
+++ b/calendar/base/modules/utils/calProviderUtils.jsm
@@ -1,14 +1,13 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 /**
  * Helpers and base class for calendar providers
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.provider namespace.
--- a/calendar/base/modules/utils/calViewUtils.jsm
+++ b/calendar/base/modules/utils/calViewUtils.jsm
@@ -6,17 +6,16 @@
  * View and DOM related helper functions
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.view namespace.
 
 const EXPORTED_SYMBOLS = ["calview"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 ChromeUtils.defineModuleGetter(lazy, "cal", "resource:///modules/calendar/calUtils.jsm");
 XPCOMUtils.defineLazyServiceGetter(
   lazy,
   "gParserUtils",
   "@mozilla.org/parserutils;1",
--- a/calendar/base/modules/utils/calWindowUtils.jsm
+++ b/calendar/base/modules/utils/calWindowUtils.jsm
@@ -6,17 +6,16 @@
  * Calendar window helpers, e.g. to open our dialogs
  */
 
 // NOTE: This module should not be loaded directly, it is available when
 // including calUtils.jsm under the cal.window namespace.
 
 const EXPORTED_SYMBOLS = ["calwindow"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 XPCOMUtils.defineLazyGetter(
   lazy,
   "l10nDeletePrompt",
   () => new Localization(["calendar/calendar-delete-prompt.ftl"], true)
 );
--- a/calendar/base/src/CalAlarmMonitor.jsm
+++ b/calendar/base/src/CalAlarmMonitor.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalAlarmMonitor"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 function peekAlarmWindow() {
   return Services.wm.getMostRecentWindow("Calendar:AlarmWindow");
 }
 
 /**
  * The alarm monitor takes care of playing the alarm sound and opening one copy
  * of the calendar-alarm-dialog. Both depend on their respective prefs to be
--- a/calendar/base/src/CalAlarmService.jsm
+++ b/calendar/base/src/CalAlarmService.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalAlarmService"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 var kHoursBetweenUpdates = 6;
 
 function nowUTC() {
   return cal.dtz.jsDateToDateTime(new Date()).getInTimezone(cal.dtz.UTC);
 }
 
--- a/calendar/base/src/CalAttachment.jsm
+++ b/calendar/base/src/CalAttachment.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalAttachment"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 /**
  * Constructor for `calIAttachment` objects.
  *
  * @class
  * @implements {calIAttachment}
  * @param {string} [icalString] - Optional iCal string for initializing existing attachments.
--- a/calendar/base/src/CalAttendee.jsm
+++ b/calendar/base/src/CalAttendee.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from calItemBase.js */
 
 var EXPORTED_SYMBOLS = ["CalAttendee"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 Services.scriptloader.loadSubScript("resource:///components/calItemBase.js");
 
 /**
  * Constructor for `calIAttendee` objects.
  *
  * @class
--- a/calendar/base/src/CalCalendarManager.jsm
+++ b/calendar/base/src/CalCalendarManager.jsm
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from calCachedCalendar.js */
 
 var EXPORTED_SYMBOLS = ["CalCalendarManager"];
 
 const { AddonManager } = ChromeUtils.import("resource://gre/modules/AddonManager.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { Preferences } = ChromeUtils.import("resource://gre/modules/Preferences.jsm");
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 const { calCachedCalendar } = ChromeUtils.import("resource:///components/calCachedCalendar.js");
 const { setTimeout } = ChromeUtils.import("resource://gre/modules/Timer.jsm");
 
 var REGISTRY_BRANCH = "calendar.registry.";
 var MAX_INT = Math.pow(2, 31) - 1;
 var MIN_INT = -MAX_INT;
--- a/calendar/base/src/CalDeletedItems.jsm
+++ b/calendar/base/src/CalDeletedItems.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalDeletedItems"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { FileUtils } = ChromeUtils.import("resource://gre/modules/FileUtils.jsm");
 
 /**
  * Handles remembering deleted items.
  *
  * This is (currently) not a real trashcan. Only ids and time deleted is stored.
  * Note also that the code doesn't strictly check the calendar of the item,
  * except when a calendar id is passed to getDeletedDate.
--- a/calendar/base/src/CalEvent.jsm
+++ b/calendar/base/src/CalEvent.jsm
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from calItemBase.js */
 
 var EXPORTED_SYMBOLS = ["CalEvent"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 Services.scriptloader.loadSubScript("resource:///components/calItemBase.js");
 
 /**
  * Constructor for `calIEvent` objects.
  *
  * @class
  * @implements {calIEvent}
--- a/calendar/base/src/CalIcsParser.jsm
+++ b/calendar/base/src/CalIcsParser.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalIcsParser"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { NetUtil } = ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 
 XPCOMUtils.defineLazyModuleGetters(lazy, {
   CalEvent: "resource:///modules/CalEvent.jsm",
   CalTodo: "resource:///modules/CalTodo.jsm",
   CalRecurrenceInfo: "resource:///modules/CalRecurrenceInfo.jsm",
--- a/calendar/base/src/CalMetronome.jsm
+++ b/calendar/base/src/CalMetronome.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalMetronome"];
 
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 const { EventEmitter } = ChromeUtils.import("resource://gre/modules/EventEmitter.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 const MINUTE_IN_MS = 60000;
 const HOUR_IN_MS = 3600000;
 const DAY_IN_MS = 86400000;
 
 /**
  * Keeps calendar UI/components in sync by ticking regularly. Fires a "minute"
  * event every minute on the minute, an "hour" event on the hour, and a "day"
--- a/calendar/base/src/CalMimeConverter.jsm
+++ b/calendar/base/src/CalMimeConverter.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalMimeConverter"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 function CalMimeConverter() {
   this.wrappedJSObject = this;
 }
 
 CalMimeConverter.prototype = {
   QueryInterface: ChromeUtils.generateQI(["nsISimpleMimeConverter"]),
--- a/calendar/base/src/CalProtocolHandler.jsm
+++ b/calendar/base/src/CalProtocolHandler.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalProtocolHandlerWebcal", "CalProtocolHandlerWebcals"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 /**
  * Generic webcal constructor
  *
  * @param scheme        The scheme to init for (webcal, webcals)
  */
 function calProtocolHandler(scheme) {
   this.scheme = scheme;
   this.mHttpProtocol = Services.io.getProtocolHandler(this.scheme == "webcal" ? "http" : "https");
--- a/calendar/base/src/CalStartupService.jsm
+++ b/calendar/base/src/CalStartupService.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalStartupService"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 /**
  * Helper function to asynchronously call a certain method on the objects passed
  * in 'services' in order (i.e wait until the first completes before calling the
  * second
  *
  * @param method        The method name to call. Usually startup/shutdown.
  * @param services      The array of service objects to call on.
  */
--- a/calendar/base/src/CalTimezoneService.jsm
+++ b/calendar/base/src/CalTimezoneService.jsm
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* import-globals-from calTimezone.js */
 
 var EXPORTED_SYMBOLS = ["CalTimezoneService"];
 
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
 var { NetUtil } = ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { ICAL, unwrapSingle } = ChromeUtils.import("resource:///modules/calendar/Ical.jsm");
 
 const lazy = {};
 
 XPCOMUtils.defineLazyPreferenceGetter(lazy, "gUseIcaljs", "calendar.icaljs", false);
--- a/calendar/base/src/CalTodo.jsm
+++ b/calendar/base/src/CalTodo.jsm
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from calItemBase.js */
 
 var EXPORTED_SYMBOLS = ["CalTodo"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 Services.scriptloader.loadSubScript("resource:///components/calItemBase.js");
 
 /**
  * Constructor for `calITodo` objects.
  *
  * @class
  * @implements {calITodo}
--- a/calendar/base/src/calApplicationUtils.js
+++ b/calendar/base/src/calApplicationUtils.js
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* exported launchBrowser */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 /**
  * Launch the given url (string) in the external browser. If an event is passed,
  * then this is only done on left click and the event propagation is stopped.
  *
  * @param url       The URL to open, as a string
  * @param event     (optional) The event that caused the URL to open
  */
 function launchBrowser(url, event) {
--- a/calendar/base/src/calCachedCalendar.js
+++ b/calendar/base/src/calCachedCalendar.js
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["calCachedCalendar"];
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var calICalendar = Ci.calICalendar;
 var cICL = Ci.calIChangeLog;
 var cIOL = Ci.calIOperationListener;
 
 var gNoOpListener = {
   QueryInterface: ChromeUtils.generateQI(["calIOperationListener"]),
   onGetResult(calendar, status, itemType, detail, items) {},
--- a/calendar/extract/CalExtractParserService.jsm
+++ b/calendar/extract/CalExtractParserService.jsm
@@ -2,17 +2,16 @@
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalExtractParserService"];
 
 const { CalExtractParser } = ChromeUtils.import(
   "resource:///modules/calendar/extract/CalExtractParser.jsm"
 );
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 const defaultRules = [
   [
     // Start clean up patterns.
 
     // remove last line preceding quoted message and first line of the quote
     [/^(\r?\n[^>].*\r?\n>+.*$)/, ""],
 
--- a/calendar/itip/CalItipEmailTransport.jsm
+++ b/calendar/itip/CalItipEmailTransport.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalItipEmailTransport", "CalItipDefaultEmailTransport"];
 
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * CalItipEmailTransport is used to send iTIP messages via email. Outside
  * callers should use the static `createInstance()` method instead of this
  * constructor directly.
  */
 class CalItipEmailTransport {
   wrappedJSObject = this;
--- a/calendar/itip/CalItipMessageSender.jsm
+++ b/calendar/itip/CalItipMessageSender.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalItipMessageSender"];
 
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { CalItipOutgoingMessage } = ChromeUtils.import(
   "resource:///modules/CalItipOutgoingMessage.jsm"
 );
 
 /**
  * CalItipMessageSender is responsible for sending out the appropriate iTIP
  * messages when changes have been made to an invitation event.
  */
--- a/calendar/providers/caldav/CalDavCalendar.jsm
+++ b/calendar/providers/caldav/CalDavCalendar.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalDavCalendar"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 var {
   CalDavGenericRequest,
   CalDavLegacySAXRequest,
   CalDavItemRequest,
   CalDavDeleteItemRequest,
   CalDavPropfindRequest,
--- a/calendar/providers/caldav/CalDavProvider.jsm
+++ b/calendar/providers/caldav/CalDavProvider.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalDavProvider"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { DNS } = ChromeUtils.import("resource:///modules/DNS.jsm");
 
 var { CalDavPropfindRequest } = ChromeUtils.import("resource:///modules/caldav/CalDavRequest.jsm");
 
 var { CalDavDetectionSession } = ChromeUtils.import("resource:///modules/caldav/CalDavSession.jsm");
 
 // NOTE: This module should not be loaded directly, it is available when
--- a/calendar/providers/caldav/modules/CalDavRequestHandlers.jsm
+++ b/calendar/providers/caldav/modules/CalDavRequestHandlers.jsm
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 var { CalDavLegacySAXRequest } = ChromeUtils.import("resource:///modules/caldav/CalDavRequest.jsm");
 
 /* exported CalDavEtagsHandler, CalDavWebDavSyncHandler, CalDavMultigetSyncHandler */
 
 const EXPORTED_SYMBOLS = [
   "CalDavEtagsHandler",
--- a/calendar/providers/ics/CalICSCalendar.jsm
+++ b/calendar/providers/ics/CalICSCalendar.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalICSCalendar"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { CalReadableStreamFactory } = ChromeUtils.import(
   "resource:///modules/CalReadableStreamFactory.jsm"
 );
 
 // This is a non-sync ics file. It reads the file pointer to by uri when set,
 // then writes it on updates. External changes to the file will be
 // ignored and overwritten.
--- a/calendar/providers/ics/CalICSProvider.jsm
+++ b/calendar/providers/ics/CalICSProvider.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CalICSProvider"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { setTimeout } = ChromeUtils.import("resource://gre/modules/Timer.jsm");
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 var { CalDavGenericRequest, CalDavPropfindRequest } = ChromeUtils.import(
   "resource:///modules/caldav/CalDavRequest.jsm"
 );
 
--- a/calendar/providers/storage/CalStorageCalendar.jsm
+++ b/calendar/providers/storage/CalStorageCalendar.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalStorageCalendar"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 const { CalReadableStreamFactory } = ChromeUtils.import(
   "resource:///modules/CalReadableStreamFactory.jsm"
 );
 const { CalStorageDatabase } = ChromeUtils.import(
   "resource:///modules/calendar/CalStorageDatabase.jsm"
 );
 const { CalStorageModelFactory } = ChromeUtils.import(
--- a/calendar/providers/storage/CalStorageDatabase.jsm
+++ b/calendar/providers/storage/CalStorageDatabase.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CalStorageDatabase"];
 
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 /**
  * CalStorageDatabase is a mozIStorageAsyncConnection wrapper used by the
  * storage calendar.
  */
 class CalStorageDatabase {
   /**
    * @type {mozIStorageAsyncConnection}
--- a/calendar/providers/storage/calStorageUpgrade.jsm
+++ b/calendar/providers/storage/calStorageUpgrade.jsm
@@ -70,17 +70,16 @@ var EXPORTED_SYMBOLS = [
   "DB_SCHEMA_VERSION",
   "getSql",
   "getAllSql",
   "getSqlTable",
   "upgradeDB",
   "backupDB",
 ];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { CAL_ITEM_FLAG, textToDate, getTimezone, newDateTime } = ChromeUtils.import(
   "resource:///modules/calendar/calStorageHelpers.jsm"
 );
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 const lazy = {};
 
--- a/calendar/test/CalendarTestUtils.jsm
+++ b/calendar/test/CalendarTestUtils.jsm
@@ -9,17 +9,16 @@ const EXPORTED_SYMBOLS = ["CalendarTestU
 const EventUtils = ChromeUtils.import("resource://testing-common/mozmill/EventUtils.jsm");
 const { BrowserTestUtils } = ChromeUtils.import("resource://testing-common/BrowserTestUtils.jsm");
 const { TestUtils } = ChromeUtils.import("resource://testing-common/TestUtils.jsm");
 const { Assert } = ChromeUtils.import("resource://testing-common/Assert.jsm");
 const { cancelItemDialog, saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 async function clickAndWait(win, button) {
   EventUtils.synthesizeMouseAtCenter(button, { clickCount: 1 }, win);
   await new Promise(resolve => win.setTimeout(resolve));
 }
 
 /**
--- a/calendar/test/CalendarUtils.jsm
+++ b/calendar/test/CalendarUtils.jsm
@@ -12,18 +12,16 @@ const EXPORTED_SYMBOLS = [
   "closeAllEventDialogs",
 ];
 
 var { Assert } = ChromeUtils.import("resource://testing-common/Assert.jsm");
 var { BrowserTestUtils } = ChromeUtils.import("resource://testing-common/BrowserTestUtils.jsm");
 var EventUtils = ChromeUtils.import("resource://testing-common/mozmill/EventUtils.jsm");
 var { TestUtils } = ChromeUtils.import("resource://testing-common/TestUtils.jsm");
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 
 ChromeUtils.defineModuleGetter(
   lazy,
   "CalendarTestUtils",
   "resource://testing-common/calendar/CalendarTestUtils.jsm"
 );
 
--- a/calendar/test/ItemEditingHelpers.jsm
+++ b/calendar/test/ItemEditingHelpers.jsm
@@ -14,17 +14,16 @@ const EXPORTED_SYMBOLS = [
 var { Assert } = ChromeUtils.import("resource://testing-common/Assert.jsm");
 var { TestUtils } = ChromeUtils.import("resource://testing-common/TestUtils.jsm");
 var { BrowserTestUtils } = ChromeUtils.import("resource://testing-common/BrowserTestUtils.jsm");
 var { sendString, synthesizeKey, synthesizeMouseAtCenter } = ChromeUtils.import(
   "resource://testing-common/mozmill/EventUtils.jsm"
 );
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { setTimeout } = ChromeUtils.import("resource://gre/modules/Timer.jsm");
 
 function sleep(window, time = 0) {
   return new Promise(resolve => window.setTimeout(resolve, time));
 }
 
 var dateFormatter = new Services.intl.DateTimeFormat(undefined, { dateStyle: "short" });
 var dateTimeFormatter = new Services.intl.DateTimeFormat(undefined, {
--- a/calendar/test/browser/browser_basicFunctionality.js
+++ b/calendar/test/browser/browser_basicFunctionality.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* globals createCalendarUsingDialog */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 add_task(async function testBasicFunctionality() {
   const calendarName = "Mochitest";
 
   registerCleanupFunction(() => {
     for (let calendar of cal.manager.getCalendars()) {
       if (calendar.name == calendarName) {
--- a/calendar/test/browser/browser_calDAV_oAuth.js
+++ b/calendar/test/browser/browser_calDAV_oAuth.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 // Creates calendars in various configurations (current and legacy) and performs
 // requests in each of them to prove that OAuth2 authentication is working as expected.
 
 var { CalDavCalendar } = ChromeUtils.import("resource:///modules/CalDavCalendar.jsm");
 var { CalDavGenericRequest } = ChromeUtils.import("resource:///modules/caldav/CalDavRequest.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var LoginInfo = Components.Constructor(
   "@mozilla.org/login-manager/loginInfo;1",
   Ci.nsILoginInfo,
   "init"
 );
 
 // Ideal login info. This is what would be saved if you created a new calendar.
--- a/calendar/test/browser/browser_localICS.js
+++ b/calendar/test/browser/browser_localICS.js
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /* globals createCalendarUsingDialog */
 
 var { saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 const HOUR = 8;
 
 // Unique name needed as deleting a calendar only unsubscribes from it and
 // if same file were used on next testrun then previously created event
 // would show up.
 var calendarName = String(Date.now());
--- a/calendar/test/browser/eventDialog/browser_utf8.js
+++ b/calendar/test/browser/eventDialog/browser_utf8.js
@@ -1,18 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { cancelItemDialog, saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var UTF8STRING = " 💣 💥  ☣  ";
 
 add_task(async function testUTF8() {
   let calendar = CalendarTestUtils.createCalendar();
   Services.prefs.setStringPref("calendar.categories.names", UTF8STRING);
 
   registerCleanupFunction(() => {
     CalendarTestUtils.removeCalendar(calendar);
--- a/calendar/test/browser/preferences/browser_alarmDefaultValue.js
+++ b/calendar/test/browser/preferences/browser_alarmDefaultValue.js
@@ -3,17 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 /**
  * Test default alarm settings for events and tasks
  */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { PluralForm } = ChromeUtils.import("resource://gre/modules/PluralForm.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var { CalendarTestUtils } = ChromeUtils.import(
   "resource://testing-common/calendar/CalendarTestUtils.jsm"
 );
 var { cancelItemDialog } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 
--- a/calendar/test/browser/providers/head.js
+++ b/calendar/test/browser/providers/head.js
@@ -11,17 +11,16 @@ var { CalendarTestUtils } = ChromeUtils.
 var { handleDeleteOccurrencePrompt } = ChromeUtils.import(
   "resource://testing-common/calendar/CalendarUtils.jsm"
 );
 
 var { PromiseUtils } = ChromeUtils.import("resource://gre/modules/PromiseUtils.jsm");
 var { saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 let calendarObserver = {
   QueryInterface: ChromeUtils.generateQI(["calIObserver"]),
 
   /* calIObserver */
 
   _batchCount: 0,
   _batchRequired: true,
--- a/calendar/test/browser/timezones/browser_timezones.js
+++ b/calendar/test/browser/timezones/browser_timezones.js
@@ -10,17 +10,16 @@ var { findEventsInNode } = ChromeUtils.i
 var { saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 var { CalendarTestUtils } = ChromeUtils.import(
   "resource://testing-common/calendar/CalendarTestUtils.jsm"
 );
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var DATES = [
   [2009, 1, 1],
   [2009, 4, 2],
   [2009, 4, 16],
   [2009, 4, 30],
   [2009, 7, 2],
   [2009, 10, 15],
--- a/calendar/test/browser/views/browser_dayView.js
+++ b/calendar/test/browser/views/browser_dayView.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { formatDate, formatTime, saveAndCloseItemDialog, setData } = ChromeUtils.import(
   "resource://testing-common/calendar/ItemEditingHelpers.jsm"
 );
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 
 const TITLE1 = "Day View Event";
 const TITLE2 = "Day View Event Changed";
--- a/calendar/test/unit/head_consts.js
+++ b/calendar/test/unit/head_consts.js
@@ -1,14 +1,13 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { AppConstants } = ChromeUtils.import("resource://gre/modules/AppConstants.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { FileUtils } = ChromeUtils.import("resource://gre/modules/FileUtils.jsm");
 
 var { updateAppInfo } = ChromeUtils.import("resource://testing-common/AppInfo.jsm");
 
 ChromeUtils.defineModuleGetter(this, "NetUtil", "resource://gre/modules/NetUtil.jsm");
 
 updateAppInfo();
 
--- a/calendar/test/unit/head_icaljs.js
+++ b/calendar/test/unit/head_icaljs.js
@@ -1,6 +1,5 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 Services.prefs.setBoolPref("calendar.icaljs", true);
--- a/calendar/test/unit/head_libical.js
+++ b/calendar/test/unit/head_libical.js
@@ -1,6 +1,5 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 Services.prefs.setBoolPref("calendar.icaljs", false);
--- a/calendar/test/unit/providers/head.js
+++ b/calendar/test/unit/providers/head.js
@@ -3,17 +3,16 @@
  * file, you can obtain one at http://mozilla.org/MPL/2.0/. */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { CalendarTestUtils } = ChromeUtils.import(
   "resource://testing-common/calendar/CalendarTestUtils.jsm"
 );
 var { CalEvent } = ChromeUtils.import("resource:///modules/CalEvent.jsm");
 var { PromiseUtils } = ChromeUtils.import("resource://gre/modules/PromiseUtils.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 // The tests in this directory each do the same thing, with slight variations as needed for each
 // calendar provider. The core of the test lives in this file and the tests call it when ready.
 
 do_get_profile();
 add_task(async () => {
   await new Promise(resolve => cal.manager.startup({ onResult: resolve }));
   await new Promise(resolve => cal.timezoneService.startup({ onResult: resolve }));
--- a/calendar/test/unit/test_alarmservice.js
+++ b/calendar/test/unit/test_alarmservice.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 var { TestUtils } = ChromeUtils.import("resource://testing-common/TestUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAlarm: "resource:///modules/CalAlarm.jsm",
   CalEvent: "resource:///modules/CalEvent.jsm",
   CalRecurrenceInfo: "resource:///modules/CalRecurrenceInfo.jsm",
 });
--- a/calendar/test/unit/test_alarmutils.js
+++ b/calendar/test/unit/test_alarmutils.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAlarm: "resource:///modules/CalAlarm.jsm",
   CalEvent: "resource:///modules/CalEvent.jsm",
   CalTodo: "resource:///modules/CalTodo.jsm",
 });
--- a/calendar/test/unit/test_calmgr.js
+++ b/calendar/test/unit/test_calmgr.js
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { CalReadableStreamFactory } = ChromeUtils.import(
   "resource:///modules/CalReadableStreamFactory.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalEvent: "resource:///modules/CalEvent.jsm",
 });
 
 /**
  * Tests the calICalendarManager interface
--- a/calendar/test/unit/test_datetimeformatter.js
+++ b/calendar/test/unit/test_datetimeformatter.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { formatter } = cal.dtz;
 
 function run_test() {
   do_calendar_startup(run_next_test);
 }
 
 // This test assumes the timezone of your system is not set to Pacific/Fakaofo or equivalent.
 
--- a/calendar/test/unit/test_imip.js
+++ b/calendar/test/unit/test_imip.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { CalItipEmailTransport } = ChromeUtils.import("resource:///modules/CalItipEmailTransport.jsm");
 
 function itipItemForTest(title, seq) {
   let itipItem = Cc["@mozilla.org/calendar/itip-item;1"].createInstance(Ci.calIItipItem);
   itipItem.init(
     [
       "BEGIN:VCALENDAR",
       "METHOD:REQUEST",
--- a/calendar/test/unit/test_invitationutils.js
+++ b/calendar/test/unit/test_invitationutils.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { cal } = ChromeUtils.import("resource:///modules/calendar/calUtils.jsm");
 var { MailServices } = ChromeUtils.import("resource:///modules/MailServices.jsm");
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import("resource://gre/modules/XPCOMUtils.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   CalAttendee: "resource:///modules/CalAttendee.jsm",
 });
 
 function run_test() {
   do_calendar_startup(run_next_test);
--- a/calendar/test/unit/test_l10n_utils.js
+++ b/calendar/test/unit/test_l10n_utils.js
@@ -1,14 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 function run_test() {
   do_calendar_startup(run_next_test);
 }
 
 // tests for calL10NUtils.jsm
 /* Incomplete - still missing test coverage for:
  * getAnyString
  * getString
--- a/calendar/test/unit/test_webcal.js
+++ b/calendar/test/unit/test_webcal.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { NetUtil } = ChromeUtils.import("resource://gre/modules/NetUtil.jsm");
 var { HttpServer } = ChromeUtils.import("resource://testing-common/httpd.js");
 
 function run_test() {
   let httpserv = new HttpServer();
   httpserv.registerPrefixHandler("/", {
     handle(request, response) {
       response.setStatusLine(request.httpVersion, 200, "OK");
--- a/chat/components/src/imAccounts.jsm
+++ b/chat/components/src/imAccounts.jsm
@@ -5,17 +5,16 @@
 var EXPORTED_SYMBOLS = ["AccountsService"];
 
 const { clearTimeout, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
 var { ClassInfo, XPCOMUtils, executeSoon, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var {
   GenericAccountPrototype,
   GenericAccountBuddyPrototype,
 } = ChromeUtils.import("resource:///modules/jsProtoHelper.jsm");
--- a/chat/components/src/imContacts.jsm
+++ b/chat/components/src/imContacts.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["TagsService", "ContactsService"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { XPCOMUtils, executeSoon, ClassInfo, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 
 const lazy = {};
 
 XPCOMUtils.defineLazyGetter(lazy, "_", () =>
--- a/chat/components/src/imConversations.jsm
+++ b/chat/components/src/imConversations.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["ConversationsService", "imMessage", "UIConversation"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { Status } = ChromeUtils.import("resource:///modules/imStatusUtils.jsm");
 var { XPCOMUtils, ClassInfo } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 var { Message } = ChromeUtils.import("resource:///modules/jsProtoHelper.jsm");
 
 var gLastUIConvId = 0;
 var gLastPrplConvId = 0;
--- a/chat/components/src/imCore.jsm
+++ b/chat/components/src/imCore.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["CoreService"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { ClassInfo, initLogModule } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 
 var kQuitApplicationGranted = "quit-application-granted";
 var kProtocolPluginCategory = "im-protocol-plugin";
 
--- a/chat/components/src/logger.jsm
+++ b/chat/components/src/logger.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["Logger"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 const { GenericMessagePrototype } = ChromeUtils.import(
   "resource:///modules/jsProtoHelper.jsm"
 );
 const { ClassInfo, l10nHelper } = ChromeUtils.import(
--- a/chat/components/src/test/test_accounts.js
+++ b/chat/components/src/test/test_accounts.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { updateAppInfo } = ChromeUtils.import(
   "resource://testing-common/AppInfo.jsm"
 );
 
 function run_test() {
   do_get_profile();
 
--- a/chat/components/src/test/test_commands.js
+++ b/chat/components/src/test/test_commands.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 // We don't load the command service via Services as we want to access
 // _findCommands in order to avoid having to intercept command execution.
 var { CommandsService } = ChromeUtils.import(
   "resource:///modules/imCommands.jsm"
 );
 
 var kPrplId = "green";
--- a/chat/components/src/test/test_conversations.js
+++ b/chat/components/src/test/test_conversations.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { GenericConvIMPrototype, Message } = ChromeUtils.import(
   "resource:///modules/jsProtoHelper.jsm"
 );
 var { imMessage, UIConversation } = ChromeUtils.import(
   "resource:///modules/imConversations.jsm"
 );
 
--- a/chat/components/src/test/test_logger.js
+++ b/chat/components/src/test/test_logger.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 do_get_profile();
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 
 var gLogger = {};
 Services.scriptloader.loadSubScript("resource:///modules/logger.jsm", gLogger);
 
 var logDirPath = PathUtils.join(
   Services.dirsvc.get("ProfD", Ci.nsIFile).path,
   "logs"
--- a/chat/content/chat-account-richlistitem.js
+++ b/chat/content/chat-account-richlistitem.js
@@ -3,19 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 "use strict";
 
 /* global MozElements, MozXULElement, gAccountManager */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { DownloadUtils } = ChromeUtils.import(
     "resource://gre/modules/DownloadUtils.jsm"
   );
   const { ChatIcons } = ChromeUtils.import("resource:///modules/chatIcons.jsm");
 
   /**
    * The MozChatAccountRichlistitem widget displays the information about the
    * configured account: i.e. icon, state, name, error, checkbox for
--- a/chat/content/chat-tooltip.js
+++ b/chat/content/chat-tooltip.js
@@ -5,17 +5,16 @@
 "use strict";
 
 /* global MozElements */
 /* global MozXULElement */
 /* global getBrowser */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  let { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
   var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
   let { ChatIcons } = ChromeUtils.import("resource:///modules/chatIcons.jsm");
   const LazyModules = {};
 
   ChromeUtils.defineModuleGetter(
     LazyModules,
     "Status",
     "resource:///modules/imStatusUtils.jsm"
--- a/chat/content/conversation-browser.js
+++ b/chat/content/conversation-browser.js
@@ -3,19 +3,16 @@
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 "use strict";
 
 /* global MozXULElement */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { XPCOMUtils } = ChromeUtils.import(
     "resource://gre/modules/XPCOMUtils.jsm"
   );
 
   const LazyModules = {};
   XPCOMUtils.defineLazyModuleGetters(LazyModules, {
     cleanupImMarkup: "resource:///modules/imContentSink.jsm",
     getCurrentTheme: "resource:///modules/imThemes.jsm",
--- a/chat/content/otr-add-fingerprint.js
+++ b/chat/content/otr-add-fingerprint.js
@@ -15,17 +15,19 @@ var otrAddFinger = {
 
     this.fingerWarning = document.getElementById("fingerWarning");
     this.fingerError = document.getElementById("fingerError");
     this.keyCount = document.getElementById("keyCount");
 
     document.l10n.setAttributes(
       document.getElementById("otrDescription"),
       "otr-add-finger-description",
-      { name: args.screenname }
+      {
+        name: args.screenname,
+      }
     );
 
     document.addEventListener("dialogaccept", event => {
       let hex = document.getElementById("fingerprint").value;
       let context = OTR.getContextFromRecipient(
         args.account,
         args.protocol,
         args.screenname
--- a/chat/content/otr-auth.js
+++ b/chat/content/otr-auth.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { XPCOMUtils, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 const { OTR } = ChromeUtils.import("resource:///modules/OTR.jsm");
 
 window.addEventListener("DOMContentLoaded", event => {
   otrAuth.onload();
--- a/chat/content/otr-finger.js
+++ b/chat/content/otr-finger.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { OTR } = ChromeUtils.import("resource:///modules/OTR.jsm");
 
 var l10n = new Localization(["messenger/otr/finger-sync.ftl"], true);
 
 window.addEventListener("DOMContentLoaded", event => {
   otrFinger.onload();
 });
--- a/chat/modules/CLib.jsm
+++ b/chat/modules/CLib.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["CLib"];
 
 const { ctypes } = ChromeUtils.import("resource://gre/modules/ctypes.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var OS = Services.appinfo.OS.toLowerCase();
 
 // type defs
 
 var FILE = ctypes.StructType("FILE");
 var fname_t = ctypes.char.ptr;
 var wchar_t = ctypes.char16_t;
--- a/chat/modules/InteractiveBrowser.jsm
+++ b/chat/modules/InteractiveBrowser.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["InteractiveBrowser", "CancelledError"];
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 class CancelledError extends Error {
   constructor() {
     super("Interactive browser request was cancelled");
   }
 }
 
 var InteractiveBrowser = {
   /**
--- a/chat/modules/OTR.jsm
+++ b/chat/modules/OTR.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const { BasePromiseWorker } = ChromeUtils.import(
   "resource://gre/modules/PromiseWorker.jsm"
 );
 const { ctypes } = ChromeUtils.import("resource://gre/modules/ctypes.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { CLib } = ChromeUtils.import("resource:///modules/CLib.jsm");
 const { OTRLibLoader } = ChromeUtils.import("resource:///modules/OTRLib.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
--- a/chat/modules/OTRLib.jsm
+++ b/chat/modules/OTRLib.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const otrl_version = [4, 1, 1];
 
 const { CLib } = ChromeUtils.import("resource:///modules/CLib.jsm");
 const { ctypes } = ChromeUtils.import("resource://gre/modules/ctypes.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var systemOS = Services.appinfo.OS.toLowerCase();
 
 var abi = ctypes.default_abi;
 
 var libotr, libotrPath;
 
 function getLibraryFilename(baseName, suffix) {
   return ctypes.libraryName(baseName) + suffix;
--- a/chat/modules/OTRUI.jsm
+++ b/chat/modules/OTRUI.jsm
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["OTRUI"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { OTR } = ChromeUtils.import("resource:///modules/OTR.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
 
--- a/chat/modules/ToLocaleFormat.jsm
+++ b/chat/modules/ToLocaleFormat.jsm
@@ -5,17 +5,16 @@
 /**
  * JS implementation of the deprecated Date.toLocaleFormat.
  * aFormat follows strftime syntax,
  * http://pubs.opengroup.org/onlinepubs/007908799/xsh/strftime.html
  */
 
 const EXPORTED_SYMBOLS = ["ToLocaleFormat"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
 XPCOMUtils.defineLazyGetter(
   lazy,
   "dateTimeFormatter",
--- a/chat/modules/imContentSink.jsm
+++ b/chat/modules/imContentSink.jsm
@@ -14,18 +14,16 @@ const EXPORTED_SYMBOLS = [
   "addGlobalAllowedTag",
   "removeGlobalAllowedTag",
   "addGlobalAllowedAttribute",
   "removeGlobalAllowedAttribute",
   "addGlobalAllowedStyleRule",
   "removeGlobalAllowedStyleRule",
 ];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var kAllowedURLs = aValue => /^(https?|ftp|mailto|magnet):/.test(aValue);
 var kAllowedMozClasses = aClassName =>
   aClassName == "moz-txt-underscore" ||
   aClassName == "moz-txt-tag" ||
   aClassName == "ib-person";
 var kAllowedAnchorClasses = aClassName => aClassName == "ib-person";
 
 /* Tags whose content should be fully removed, and reported in the Error Console. */
--- a/chat/modules/imSmileys.jsm
+++ b/chat/modules/imSmileys.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /** Used to add smileys to the content of a textnode. */
 
 const EXPORTED_SYMBOLS = ["smileTextNode"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
 
 XPCOMUtils.defineLazyGetter(lazy, "gTextDecoder", () => {
   return new TextDecoder();
--- a/chat/modules/imTextboxUtils.jsm
+++ b/chat/modules/imTextboxUtils.jsm
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["TextboxSize"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var TextboxSize = {
   _textboxAutoResizePrefName: "messenger.conversations.textbox.autoResize",
   get autoResize() {
     delete this.autoResize;
     Services.prefs.addObserver(this._textboxAutoResizePrefName, this);
     return (this.autoResize = Services.prefs.getBoolPref(
       this._textboxAutoResizePrefName
     ));
--- a/chat/modules/imThemes.jsm
+++ b/chat/modules/imThemes.jsm
@@ -13,17 +13,16 @@ const EXPORTED_SYMBOLS = [
   "getMessagesForRange",
   "serializeSelection",
   "getDocumentFragmentFromHTML",
   "replaceHTMLForMessage",
   "wasNextMessage",
   "removeMessage",
 ];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
 
 ChromeUtils.defineModuleGetter(
   lazy,
--- a/chat/modules/imXPCOMUtils.jsm
+++ b/chat/modules/imXPCOMUtils.jsm
@@ -11,17 +11,16 @@ const EXPORTED_SYMBOLS = [
   "l10nHelper",
   "initLogModule",
   "scriptError",
 ];
 
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var kLogLevelPref = "purple.debug.loglevel";
 
 /**
  * Creates an nsIScriptError instance and logs it.
  *
  * @param aModule
  *        string identifying the module within which the error occurred.
--- a/chat/modules/jsProtoHelper.jsm
+++ b/chat/modules/jsProtoHelper.jsm
@@ -17,17 +17,16 @@ const EXPORTED_SYMBOLS = [
 ];
 
 const {
   initLogModule,
   XPCOMUtils,
   nsSimpleEnumerator,
   l10nHelper,
 } = ChromeUtils.import("resource:///modules/imXPCOMUtils.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { ClassInfo } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 
 const lazy = {};
 
 XPCOMUtils.defineLazyGetter(lazy, "_", () =>
--- a/chat/modules/socket.jsm
+++ b/chat/modules/socket.jsm
@@ -66,17 +66,16 @@
  * To Do:
  *   Add a message queue to keep from flooding a server (just an array, just
  *     keep shifting the first element off and calling as setTimeout for the
  *     desired flood time?).
  */
 
 const EXPORTED_SYMBOLS = ["Socket"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { executeSoon } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 const { clearTimeout, requestIdleCallback, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
 
 // Network errors see: xpcom/base/nsError.h
--- a/chat/modules/test/test_filtering.js
+++ b/chat/modules/test/test_filtering.js
@@ -1,15 +1,14 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
 // These tests run into issues if there isn't a profile directory, see bug 1542397.
 do_get_profile();
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var {
   cleanupImMarkup,
   createDerivedRuleset,
   addGlobalAllowedTag,
   removeGlobalAllowedTag,
   addGlobalAllowedAttribute,
   removeGlobalAllowedAttribute,
--- a/chat/protocols/irc/irc.jsm
+++ b/chat/protocols/irc/irc.jsm
@@ -17,17 +17,16 @@ var {
   XPCOMUtils,
   nsSimpleEnumerator,
 } = ChromeUtils.import("resource:///modules/imXPCOMUtils.jsm");
 
 var { clearTimeout, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { ctcpFormatToHTML, kListRefreshInterval } = ChromeUtils.import(
   "resource:///modules/ircUtils.jsm"
 );
 var { ircHandlers } = ChromeUtils.import("resource:///modules/ircHandlers.jsm");
 var {
   GenericAccountPrototype,
   GenericAccountBuddyPrototype,
@@ -319,30 +318,36 @@ var GenericIRCConversation = {
       return;
     }
 
     if (action) {
       if (!this._account.sendCTCPMessage(this.name, false, "ACTION", message)) {
         this.writeMessage(
           this._account._currentServerName,
           lazy._("error.sendMessageFailed"),
-          { error: true, system: true }
+          {
+            error: true,
+            system: true,
+          }
         );
         return;
       }
     } else if (
       !this._account.sendMessage(isNotice ? "NOTICE" : "PRIVMSG", [
         this.name,
         message,
       ])
     ) {
       this.writeMessage(
         this._account._currentServerName,
         lazy._("error.sendMessageFailed"),
-        { error: true, system: true }
+        {
+          error: true,
+          system: true,
+        }
       );
       return;
     }
 
     // By default the server doesn't send the message back, but this can be
     // enabled with the echo-message capability. If this is not enabled, just
     // assume the message was received and immediately show it.
     if (!this._account._activeCAPs.has("echo-message")) {
--- a/chat/protocols/irc/ircCTCP.jsm
+++ b/chat/protocols/irc/ircCTCP.jsm
@@ -5,17 +5,16 @@
 /**
  * This implements the Client-to-Client Protocol (CTCP), a subprotocol of IRC.
  *   REVISED AND UPDATED CTCP SPECIFICATION
  *     http://www.alien.net.au/irc/ctcp.txt
  */
 
 const EXPORTED_SYMBOLS = ["ircCTCP", "ctcpBase", "CTCPMessage"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 const lazy = {};
 XPCOMUtils.defineLazyGetter(lazy, "_", () =>
   l10nHelper("chrome://chat/locale/irc.properties")
 );
 
@@ -285,15 +284,18 @@ var ctcpBase = {
         let response = lazy._(
           "ctcp.version",
           aMessage.origin,
           aMessage.ctcp.param
         );
         this.getConversation(aMessage.origin).writeMessage(
           aMessage.origin,
           response,
-          { system: true, tags: aMessage.tags }
+          {
+            system: true,
+            tags: aMessage.tags,
+          }
         );
       }
       return true;
     },
   },
 };
--- a/chat/protocols/irc/ircCommands.jsm
+++ b/chat/protocols/irc/ircCommands.jsm
@@ -1,17 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 // This is to be exported directly onto the IRC prplIProtocol object, directly
 // implementing the commands field before we register them.
 const EXPORTED_SYMBOLS = ["commands"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 const lazy = {};
 XPCOMUtils.defineLazyGetter(lazy, "_", () =>
   l10nHelper("chrome://chat/locale/irc.properties")
 );
 
@@ -313,17 +312,20 @@ var commands = [
                   let roomInfo = account.getRoomInfo(name);
                   serverConv.writeMessage(
                     serverName,
                     name +
                       " (" +
                       roomInfo.participantCount +
                       ") " +
                       roomInfo.topic,
-                    { incoming: true, noLog: true }
+                    {
+                      incoming: true,
+                      noLog: true,
+                    }
                   );
                 } while (pendingChats.length);
               })();
             }
             pendingChats = pendingChats.concat(aRooms);
           },
         },
         true
--- a/chat/protocols/irc/ircNonStandard.jsm
+++ b/chat/protocols/irc/ircNonStandard.jsm
@@ -95,17 +95,20 @@ var ircNonStandard = {
       // Note that if the user's nick is auth this COULD be a notice directed at
       // them. For reference: moznet sends Auth (previously sent AUTH), freenode
       // sends *.
       let isAuth = target == "auth" && this._nickname.toLowerCase() != "auth";
       if (!aMessage.params[1].startsWith("***") && !isAuth) {
         this.getConversation(aMessage.origin).writeMessage(
           aMessage.origin,
           aMessage.params[1],
-          { incoming: true, tags: aMessage.tags }
+          {
+            incoming: true,
+            tags: aMessage.tags,
+          }
         );
         return true;
       }
 
       return false;
     },
 
     "042": function(aMessage) {
@@ -247,14 +250,17 @@ var ircNonStandard = {
       return this.setWhois(aMessage.params[1], { secure: true });
     },
 
     "998": function(aMessage) {
       // irc.umich.edu shows an ASCII captcha that must be typed in by the user.
       this.getConversation(aMessage.origin).writeMessage(
         aMessage.origin,
         aMessage.params[1],
-        { incoming: true, noFormat: true }
+        {
+          incoming: true,
+          noFormat: true,
+        }
       );
       return true;
     },
   },
 };
--- a/chat/protocols/irc/ircServices.jsm
+++ b/chat/protocols/irc/ircServices.jsm
@@ -185,17 +185,19 @@ var servicesBase = {
         this._infoServMotd = [text];
         return true;
       } else if (text == "*** \u0002End of Message(s) of the Day\u0002 ***") {
         if (this._showServerTab && this._infoServMotd) {
           this._infoServMotd.push(text);
           this.getConversation(aMessage.origin).writeMessage(
             aMessage.origin,
             this._infoServMotd.join("\n"),
-            { incoming: true }
+            {
+              incoming: true,
+            }
           );
           delete this._infoServMotd;
         }
         return true;
       } else if (this.hasOwnProperty("_infoServMotd")) {
         this._infoServMotd.push(text);
         return true;
       }
--- a/chat/protocols/irc/ircUtils.jsm
+++ b/chat/protocols/irc/ircUtils.jsm
@@ -239,17 +239,20 @@ function conversationErrorMessage(
   aError,
   aJoinFailed = false,
   aRejoinable = true
 ) {
   let conv = aAccount.getConversation(aMessage.params[1]);
   conv.writeMessage(
     aMessage.origin,
     lazy._(aError, aMessage.params[1], aMessage.params[2] || undefined),
-    { error: true, system: true }
+    {
+      error: true,
+      system: true,
+    }
   );
   delete conv._pendingMessage;
 
   // Channels have a couple extra things that can be done to them.
   if (aAccount.isMUCName(aMessage.params[1])) {
     // If a value for joining is explicitly given, mark it.
     if (aJoinFailed) {
       conv.joining = false;
--- a/chat/protocols/irc/test/test_ctcpDequote.js
+++ b/chat/protocols/irc/test/test_ctcpDequote.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { CTCPMessage } = ChromeUtils.import("resource:///modules/ircCTCP.jsm");
 
 var input = [
   "ACTION",
   "ACTION test",
   "ACTION \x5Ctest",
   "ACTION te\x5Cst",
   "ACTION test\x5C",
--- a/chat/protocols/irc/test/test_ctcpQuote.js
+++ b/chat/protocols/irc/test/test_ctcpQuote.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircAccount } = ChromeUtils.import("resource:///modules/irc.jsm");
 
 var input = [
   undefined,
   "test",
   "\\test",
   "te\\st",
   "test\\",
--- a/chat/protocols/irc/test/test_ircCAP.js
+++ b/chat/protocols/irc/test/test_ircCAP.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { capMessage } = ChromeUtils.import("resource:///modules/ircCAP.jsm");
 
 var testData = [
   // A normal LS from the server.
   [
     ["*", "LS", "multi-prefix sasl userhost-in-names"],
     [
       {
--- a/chat/protocols/irc/test/test_ircChannel.js
+++ b/chat/protocols/irc/test/test_ircChannel.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircChannel } = ChromeUtils.import("resource:///modules/irc.jsm");
 
 function waitForTopic(target, targetTopic) {
   return new Promise(resolve => {
     let observer = {
       observe(subject, topic, data) {
         if (topic === targetTopic) {
           resolve({ subject, data });
--- a/chat/protocols/irc/test/test_ircCommands.js
+++ b/chat/protocols/irc/test/test_ircCommands.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { commands } = ChromeUtils.import("resource:///modules/ircCommands.jsm");
 var { ircProtocol, ircAccount, ircConversation } = ChromeUtils.import(
   "resource:///modules/irc.jsm"
 );
 
 // Ensure the commands have been initialized.
 IMServices.conversations.initConversations();
--- a/chat/protocols/irc/test/test_ircMessage.js
+++ b/chat/protocols/irc/test/test_ircMessage.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircAccount, ircMessage } = ChromeUtils.import(
   "resource:///modules/irc.jsm"
 );
 
 var testData = [
   // First off, let's test the messages from RFC 2812.
   "PASS secretpasswordhere",
   "NICK Wiz",
--- a/chat/protocols/irc/test/test_ircNonStandard.js
+++ b/chat/protocols/irc/test/test_ircNonStandard.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircMessage } = ChromeUtils.import("resource:///modules/irc.jsm");
 const { ircNonStandard } = ChromeUtils.import(
   "resource:///modules/ircNonStandard.jsm"
 );
 
 // The function that is under test here.
 var NOTICE = ircNonStandard.commands.NOTICE;
 
--- a/chat/protocols/irc/test/test_ircProtocol.js
+++ b/chat/protocols/irc/test/test_ircProtocol.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { ircProtocol } = ChromeUtils.import("resource:///modules/irc.jsm");
 
 add_task(function test_splitUsername() {
   const bareUsername = "foobar";
   const bareSplit = ircProtocol.prototype.splitUsername(bareUsername);
   deepEqual(bareSplit, []);
 
   const fullAccountName = "foobar@example.com";
--- a/chat/protocols/irc/test/test_ircServerTime.js
+++ b/chat/protocols/irc/test/test_ircServerTime.js
@@ -1,15 +1,14 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
 var { tagServerTime } = ChromeUtils.import(
   "resource:///modules/ircServerTime.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircMessage } = ChromeUtils.import("resource:///modules/irc.jsm");
 
 function getTags(aRawMsg) {
   const { tags } = ircMessage(aRawMsg, "does.not@matter");
 
   return tags;
 }
 
--- a/chat/protocols/irc/test/test_sendBufferedCommand.js
+++ b/chat/protocols/irc/test/test_sendBufferedCommand.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { ircAccount } = ChromeUtils.import("resource:///modules/irc.jsm");
 var { clearTimeout, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
 
 function FakeAccount() {
   this._commandBuffers = new Map();
--- a/chat/protocols/irc/test/test_setMode.js
+++ b/chat/protocols/irc/test/test_setMode.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var { ircAccount, ircChannel } = ChromeUtils.import(
   "resource:///modules/irc.jsm"
 );
 
 IMServices.conversations.initConversations();
 
 function FakeAccount() {
--- a/chat/protocols/irc/test/test_splitLongMessages.js
+++ b/chat/protocols/irc/test/test_splitLongMessages.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var irc = {};
 Services.scriptloader.loadSubScript("resource:///modules/irc.jsm", irc);
 
 var messages = {
   // Exactly 51 characters.
   "This is a test.": ["This is a test."],
   // Too long.
   "This is a message that is too long.": [
--- a/chat/protocols/irc/test/test_tryNewNick.js
+++ b/chat/protocols/irc/test/test_tryNewNick.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { ircProtocol, ircAccount } = ChromeUtils.import(
   "resource:///modules/irc.jsm"
 );
 
 var fakeProto = {
   id: "fake-proto",
   options: { alternateNicks: "" },
   _getOptionDefault(aOption) {
--- a/chat/protocols/matrix/matrix-sdk.jsm
+++ b/chat/protocols/matrix/matrix-sdk.jsm
@@ -7,17 +7,16 @@ const {
   clearInterval,
   clearTimeout,
   setInterval,
   setTimeout,
 } = ChromeUtils.import("resource://gre/modules/Timer.jsm");
 const { scriptError } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 const { Loader, Require, Module } = ChromeUtils.import(
   "resource://devtools/shared/loader/base-loader.js"
 );
 
 const EXPORTED_SYMBOLS = [
   "MatrixSDK",
   "getHttpUriForMxc",
--- a/chat/protocols/matrix/matrix.jsm
+++ b/chat/protocols/matrix/matrix.jsm
@@ -10,17 +10,16 @@ var EXPORTED_SYMBOLS = [
 ];
 
 const { clearTimeout, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
 var { XPCOMUtils, nsSimpleEnumerator, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 var {
   GenericAccountPrototype,
   GenericConvChatPrototype,
   GenericConvChatBuddyPrototype,
   GenericProtocolPrototype,
   GenericConversationPrototype,
   GenericConvIMPrototype,
@@ -1459,17 +1458,19 @@ MatrixRoom.prototype = {
   },
   initializeEncryption() {
     if (this._account._client.isRoomEncrypted(this._roomId)) {
       return;
     }
     this._account._client.sendStateEvent(
       this._roomId,
       lazy.MatrixSDK.EventType.RoomEncryption,
-      { algorithm: lazy.OlmLib.MEGOLM_ALGORITHM }
+      {
+        algorithm: lazy.OlmLib.MEGOLM_ALGORITHM,
+      }
     );
   },
 };
 
 /**
  * Initialize the verification, choosing the challenge method and calculating
  * the challenge string and description.
  *
--- a/chat/protocols/matrix/test/head.js
+++ b/chat/protocols/matrix/test/head.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const {
   MatrixProtocol,
   MatrixRoom,
   MatrixAccount,
   MatrixMessage,
 } = ChromeUtils.import("resource:///modules/matrix.jsm");
 var { MatrixSDK } = ChromeUtils.import("resource:///modules/matrix-sdk.jsm");
--- a/chat/protocols/odnoklassniki/odnoklassniki.jsm
+++ b/chat/protocols/odnoklassniki/odnoklassniki.jsm
@@ -2,17 +2,16 @@
  * 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/. */
 
 var EXPORTED_SYMBOLS = ["OdnoklassnikiProtocol"];
 
 var { XPCOMUtils, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { GenericProtocolPrototype } = ChromeUtils.import(
   "resource:///modules/jsProtoHelper.jsm"
 );
 var { XMPPAccountPrototype } = ChromeUtils.import(
   "resource:///modules/xmpp-base.jsm"
 );
 var { XMPPSession } = ChromeUtils.import(
   "resource:///modules/xmpp-session.jsm"
--- a/chat/protocols/xmpp/sax.jsm
+++ b/chat/protocols/xmpp/sax.jsm
@@ -1,11 +1,9 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["SAX"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 let scope = {};
 Services.scriptloader.loadSubScript("resource:///modules/sax/sax.js", scope);
 var SAX = scope.sax;
--- a/chat/protocols/xmpp/test/test_dnsSrv.js
+++ b/chat/protocols/xmpp/test/test_dnsSrv.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XMPPAccountPrototype } = ChromeUtils.import(
   "resource:///modules/xmpp-base.jsm"
 );
 var { XMPPSession } = ChromeUtils.import(
   "resource:///modules/xmpp-session.jsm"
 );
 var { SRVRecord } = ChromeUtils.import("resource:///modules/DNS.jsm");
 
--- a/chat/protocols/xmpp/test/test_parseJidAndNormalization.js
+++ b/chat/protocols/xmpp/test/test_parseJidAndNormalization.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XMPPAccountPrototype } = ChromeUtils.import(
   "resource:///modules/xmpp-base.jsm"
 );
 
 var TEST_DATA = {
   "abdelrhman@instantbird": {
     node: "abdelrhman",
     domain: "instantbird",
--- a/chat/protocols/xmpp/test/test_saslPrep.js
+++ b/chat/protocols/xmpp/test/test_saslPrep.js
@@ -1,13 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var { saslPrep } = ChromeUtils.import("resource:///modules/xmpp-authmechs.jsm");
 
 // RFC 4013 3.Examples
 var TEST_DATA = [
   {
     // SOFT HYPHEN mapped to nothing.
     input: "I\u00adX",
     output: "IX",
--- a/chat/protocols/xmpp/test/test_xmppXml.js
+++ b/chat/protocols/xmpp/test/test_xmppXml.js
@@ -1,12 +1,11 @@
 /* Any copyright is dedicated to the Public Domain.
  * http://creativecommons.org/publicdomain/zero/1.0/ */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { Stanza } = ChromeUtils.import("resource:///modules/xmpp-xml.jsm");
 
 var TEST_DATA = [
   {
     input: {
       name: "message",
       namespace: Stanza.NS.client,
       attributes: {
--- a/chat/protocols/xmpp/xmpp-base.jsm
+++ b/chat/protocols/xmpp/xmpp-base.jsm
@@ -7,17 +7,16 @@ const EXPORTED_SYMBOLS = [
   "XMPPMUCConversationPrototype",
   "XMPPAccountBuddyPrototype",
   "XMPPAccountPrototype",
 ];
 
 const { clearTimeout, setTimeout } = ChromeUtils.import(
   "resource://gre/modules/Timer.jsm"
 );
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { IMServices } = ChromeUtils.import("resource:///modules/IMServices.jsm");
 const { Status } = ChromeUtils.import("resource:///modules/imStatusUtils.jsm");
 const {
   XPCOMUtils,
   executeSoon,
   nsSimpleEnumerator,
   EmptyEnumerator,
   ClassInfo,
--- a/chat/protocols/xmpp/xmpp-commands.jsm
+++ b/chat/protocols/xmpp/xmpp-commands.jsm
@@ -331,17 +331,19 @@ var commands = [
         return true;
       }
 
       // We do not have user's resource.
       if (!conv._targetResource) {
         conv.writeMessage(
           conv.name,
           lazy._("conversation.error.resourceNotAvailable", conv.shortName),
-          { system: true }
+          {
+            system: true,
+          }
         );
         return true;
       }
 
       conv.getVersion();
       return true;
     },
   },
--- a/chat/protocols/xmpp/xmpp-session.jsm
+++ b/chat/protocols/xmpp/xmpp-session.jsm
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 const EXPORTED_SYMBOLS = ["XMPPSession"];
 
 const { DNS } = ChromeUtils.import("resource:///modules/DNS.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils, l10nHelper } = ChromeUtils.import(
   "resource:///modules/imXPCOMUtils.jsm"
 );
 var { Socket } = ChromeUtils.import("resource:///modules/socket.jsm");
 var { Stanza, XMPPParser } = ChromeUtils.import(
   "resource:///modules/xmpp-xml.jsm"
 );
 var { XMPPAuthMechanisms } = ChromeUtils.import(
--- a/mail/actors/LinkClickHandlerChild.jsm
+++ b/mail/actors/LinkClickHandlerChild.jsm
@@ -5,17 +5,16 @@
 
 "use strict";
 
 const EXPORTED_SYMBOLS = [
   "LinkClickHandlerChild",
   "StrictLinkClickHandlerChild",
 ];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 const { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 const lazy = {};
 
 XPCOMUtils.defineLazyServiceGetter(
   lazy,
--- a/mail/actors/LinkHandlerParent.jsm
+++ b/mail/actors/LinkHandlerParent.jsm
@@ -1,18 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 "use strict";
 
 const EXPORTED_SYMBOLS = ["LinkHandlerParent"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 class LinkHandlerParent extends JSWindowActorParent {
   receiveMessage(msg) {
     let browser = this.browsingContext.top.embedderElement;
     if (!browser) {
       return;
     }
 
     switch (msg.name) {
--- a/mail/actors/MailLinkParent.jsm
+++ b/mail/actors/MailLinkParent.jsm
@@ -6,17 +6,16 @@
 "use strict";
 
 const EXPORTED_SYMBOLS = ["MailLinkParent"];
 
 const { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 const { MailUtils } = ChromeUtils.import("resource:///modules/MailUtils.jsm");
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 class MailLinkParent extends JSWindowActorParent {
   receiveMessage(value) {
     switch (value.name) {
       case "imap:":
       case "mailbox:":
         this._handleMailboxLink(value);
         break;
--- a/mail/actors/PromptParent.jsm
+++ b/mail/actors/PromptParent.jsm
@@ -2,18 +2,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 "use strict";
 
 var EXPORTED_SYMBOLS = ["PromptParent"];
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 const lazy = {};
 
 ChromeUtils.defineModuleGetter(
   lazy,
   "PromptUtils",
   "resource://gre/modules/SharedPromptUtils.jsm"
 );
 
--- a/mail/base/content/FilterListDialog.js
+++ b/mail/base/content/FilterListDialog.js
@@ -1,17 +1,16 @@
 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 var { PluralForm } = ChromeUtils.import(
   "resource://gre/modules/PluralForm.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 var gFilterListMsgWindow = null;
 var gCurrentFilterList;
 var gServerMenu = null;
 var gFilterListbox = null;
--- a/mail/base/content/SearchDialog.js
+++ b/mail/base/content/SearchDialog.js
@@ -7,17 +7,16 @@
 /* import-globals-from folderDisplay.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from mailWindowOverlay.js */
 /* import-globals-from messageDisplay.js */
 /* import-globals-from threadPane.js */
 
 "use strict";
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailUtils } = ChromeUtils.import("resource:///modules/MailUtils.jsm");
 var { PluralForm } = ChromeUtils.import(
   "resource://gre/modules/PluralForm.jsm"
 );
 var { TagUtils } = ChromeUtils.import("resource:///modules/TagUtils.jsm");
 
 var gCurrentFolder;
 
--- a/mail/base/content/about3Pane.js
+++ b/mail/base/content/about3Pane.js
@@ -7,17 +7,16 @@
 /* globals goDoCommand */ // globalOverlay.js
 
 var { DBViewWrapper } = ChromeUtils.import(
   "resource:///modules/DBViewWrapper.jsm"
 );
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   FeedUtils: "resource:///modules/FeedUtils.jsm",
   FolderUtils: "resource:///modules/FolderUtils.jsm",
   GlodaSyntheticView: "resource:///modules/gloda/GlodaSyntheticView.jsm",
--- a/mail/base/content/aboutDialog-appUpdater.js
+++ b/mail/base/content/aboutDialog-appUpdater.js
@@ -1,16 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 // Note: this file is included in aboutDialog.xhtml and preferences/advanced.xhtml
 // if MOZ_UPDATER is defined.
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 var { DownloadUtils } = ChromeUtils.import(
   "resource://gre/modules/DownloadUtils.jsm"
 );
 
 ChromeUtils.defineModuleGetter(
--- a/mail/base/content/aboutDialog.js
+++ b/mail/base/content/aboutDialog.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from aboutDialog-appUpdater.js */
 
 "use strict";
 
 // Services = object with smart getters for common XPCOM services
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 
 function init(aEvent) {
   if (aEvent.target != document) {
     return;
   }
--- a/mail/base/content/aboutMessage.js
+++ b/mail/base/content/aboutMessage.js
@@ -9,17 +9,16 @@
 
 // mailWindowOverlay.js
 /* globals ClearPendingReadTimer, gMessageNotificationBar */
 
 // msgHdrView.js
 /* globals HideMessageHeaderPane, messageHeaderSink, gMessageListeners,
    OnLoadMsgHeaderPane, OnTagsChange, OnUnloadMsgHeaderPane */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   DBViewWrapper: "resource:///modules/DBViewWrapper.jsm",
   DownloadPaths: "resource://gre/modules/DownloadPaths.jsm",
   JSTreeSelection: "resource:///modules/JsTreeSelection.jsm",
--- a/mail/base/content/commandglue.js
+++ b/mail/base/content/commandglue.js
@@ -10,17 +10,16 @@
 /* import-globals-from folderPane.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from msgMail3PaneWindow.js */
 /* global BigInt */
 
 var { MailViewConstants } = ChromeUtils.import(
   "resource:///modules/MailViewManager.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 function UpdateMailToolbar(caller) {
   if (Services.prefs.getBoolPref("mail.useNewMailTabs")) {
     return;
   }
 
   // If we have a transient selection, we shouldn't update the toolbar. We'll
   // update it once we've restored the original selection.
--- a/mail/base/content/compactFoldersDialog.js
+++ b/mail/base/content/compactFoldersDialog.js
@@ -1,14 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var propBag, args;
 
 document.addEventListener("DOMContentLoaded", compactDialogOnDOMContentLoaded);
 // Bug 1720540: Call sizeToContent only after the entire window has been loaded,
 // including the shadow DOM and the updated fluent strings.
 window.addEventListener("load", window.sizeToContent);
 
 function compactDialogOnDOMContentLoaded() {
--- a/mail/base/content/contentAreaClick.js
+++ b/mail/base/content/contentAreaClick.js
@@ -2,17 +2,16 @@
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from ../../../../toolkit/content/contentAreaUtils.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from utilityOverlay.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { PlacesUtils } = ChromeUtils.import(
   "resource://gre/modules/PlacesUtils.jsm"
 );
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 XPCOMUtils.defineLazyModuleGetters(this, {
   PhishingDetector: "resource:///modules/PhishingDetector.jsm",
--- a/mail/base/content/customElements.js
+++ b/mail/base/content/customElements.js
@@ -2,18 +2,16 @@
  * 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/. */
 
 "use strict";
 
 // This is loaded into chrome windows with the subscript loader. Wrap in
 // a block to prevent accidentally leaking globals onto `window`.
 (() => {
-  var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
   // If toolkit customElements weren't already loaded, do it now.
   if (!window.MozXULElement) {
     Services.scriptloader.loadSubScript(
       "chrome://global/content/customElements.js",
       window
     );
   }
 
--- a/mail/base/content/customizeToolbar.js
+++ b/mail/base/content/customizeToolbar.js
@@ -4,17 +4,16 @@
 
 var gToolboxDocument = null;
 var gToolbox = null;
 var gCurrentDragOverItem = null;
 var gToolboxChanged = false;
 var gToolboxSheet = false;
 var gPaletteBox = null;
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 
 function onLoad() {
   if ("arguments" in window && window.arguments[0]) {
     InitWithToolbox(window.arguments[0]);
     repositionDialog(window);
--- a/mail/base/content/editContactPanel.js
+++ b/mail/base/content/editContactPanel.js
@@ -1,15 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from mailCore.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 var editContactInlineUI = {
   _overlayLoaded: false,
   _overlayLoading: false,
   _cardDetails: null,
--- a/mail/base/content/folderPane.js
+++ b/mail/base/content/folderPane.js
@@ -12,17 +12,16 @@
 /* import-globals-from mailWindow.js */
 
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   FeedUtils: "resource:///modules/FeedUtils.jsm",
   FolderUtils: "resource:///modules/FolderUtils.jsm",
   MailUtils: "resource:///modules/MailUtils.jsm",
 });
 
 var kDefaultMode = "all";
@@ -3702,17 +3701,21 @@ var gFolderTreeController = {
     if (aName) {
       name += "-" + aName;
     }
 
     window.openDialog(
       "chrome://messenger/content/virtualFolderProperties.xhtml",
       "",
       "chrome,modal,centerscreen",
-      { folder, searchTerms: aSearchTerms, newFolderName: name }
+      {
+        folder,
+        searchTerms: aSearchTerms,
+        newFolderName: name,
+      }
     );
   },
 
   editVirtualFolder(aFolder) {
     let folder = aFolder || gFolderTreeView.getSelectedFolders()[0];
 
     // xxx should pass the folder object
     function editVirtualCallback(aURI) {
--- a/mail/base/content/glodaFacetTab.js
+++ b/mail/base/content/glodaFacetTab.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { FacetDriver } = ChromeUtils.import("resource:///modules/gloda/Facet.jsm");
 var { GlodaMsgSearcher } = ChromeUtils.import(
   "resource:///modules/gloda/GlodaMsgSearcher.jsm"
 );
 
 var glodaFacetTabType = {
   name: "glodaFacet",
   perTabPanel: "vbox",
--- a/mail/base/content/glodaFacetView.js
+++ b/mail/base/content/glodaFacetView.js
@@ -10,17 +10,16 @@
  * Because much of the work related to faceting is not UI-specific, we try and
  *  push as much of it into mailnews/db/gloda/Facet.jsm.  In some cases we may
  *  get it wrong and it may eventually want to migrate.
  */
 
 var { PluralForm } = ChromeUtils.import(
   "resource://gre/modules/PluralForm.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 var { TagUtils } = ChromeUtils.import("resource:///modules/TagUtils.jsm");
 var { Gloda } = ChromeUtils.import("resource:///modules/gloda/GlodaPublic.jsm");
 var { FacetDriver, FacetUtils } = ChromeUtils.import(
   "resource:///modules/gloda/Facet.jsm"
 );
--- a/mail/base/content/macMessengerMenu.js
+++ b/mail/base/content/macMessengerMenu.js
@@ -1,16 +1,15 @@
 /* -*- Mode: Javascript; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from mailCore.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 // Load and add the menu item to the OS X Dock icon menu.
 addEventListener(
   "load",
   function() {
--- a/mail/base/content/mail-offline.js
+++ b/mail/base/content/mail-offline.js
@@ -1,17 +1,15 @@
 /* -*- Mode: Javascript; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* import-globals-from mailWindow.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var MailOfflineMgr = {
   offlineManager: null,
   offlineBundle: null,
 
   init() {
     Services.obs.addObserver(this, "network:offline-status-changed");
 
     this.offlineManager = Cc[
--- a/mail/base/content/mail3PaneWindowCommands.js
+++ b/mail/base/content/mail3PaneWindowCommands.js
@@ -13,17 +13,16 @@
 /* import-globals-from commandglue.js */
 /* import-globals-from folderDisplay.js */
 /* import-globals-from mailCore.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from msgViewNavigation.js */
 /* import-globals-from threadPane.js */
 /* import-globals-from utilityOverlay.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 var { PluralForm } = ChromeUtils.import(
   "resource://gre/modules/PluralForm.jsm"
 );
 ChromeUtils.defineModuleGetter(
   this,
--- a/mail/base/content/mailContext.js
+++ b/mail/base/content/mailContext.js
@@ -6,17 +6,16 @@
 
 /* globals goDoCommand */ // globalOverlay.js
 /* globals CrossFolderNavigation */ // msgViewNavigation.js
 /* globals displayMessage, gDBView, gFolder, gViewWrapper, messengerBundle */
 
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 var LazyModules = {};
 XPCOMUtils.defineLazyModuleGetters(LazyModules, {
   ConversationOpener: "resource:///modules/ConversationOpener.jsm",
   MailUtils: "resource:///modules/MailUtils.jsm",
@@ -272,17 +271,19 @@ var mailContextMenu = {
     window.browsingContext.topChromeWindow.initMoveToFolderAgainMenu(
       document.getElementById("mailContext-moveToFolderAgain")
     );
 
     // setSingleSelection("mailContext-calendar-convert-menu");
     document.l10n.setAttributes(
       document.getElementById("mailContext-delete"),
       "mail-context-delete-messages",
-      { count: numSelectedMessages }
+      {
+        count: numSelectedMessages,
+      }
     );
 
     checkItem(
       "mailContext-ignoreThread",
       folder?.msgDatabase.IsIgnored(message.messageKey)
     );
     checkItem(
       "mailContext-ignoreSubthread",
--- a/mail/base/content/mailContextMenus.js
+++ b/mail/base/content/mailContextMenus.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 /* import-globals-from commandglue.js */
 /* import-globals-from folderDisplay.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from nsContextMenu.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { PluralForm } = ChromeUtils.import(
   "resource://gre/modules/PluralForm.jsm"
 );
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 /**
--- a/mail/base/content/mailCore.js
+++ b/mail/base/content/mailCore.js
@@ -13,17 +13,16 @@
  */
 
 /* import-globals-from ../../extensions/mailviews/content/msgViewPickerOverlay.js */
 /* import-globals-from commandglue.js */
 /* import-globals-from customizeToolbar.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from utilityOverlay.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 XPCOMUtils.defineLazyGetter(this, "gViewSourceUtils", function() {
--- a/mail/base/content/mailWindow.js
+++ b/mail/base/content/mailWindow.js
@@ -12,17 +12,16 @@
 /* import-globals-from mailWindowOverlay.js */
 /* import-globals-from msgHdrView.js */
 /* import-globals-from msgMail3PaneWindow.js */
 /* import-globals-from utilityOverlay.js */
 
 // From netError.js
 /* globals retryThis */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 XPCOMUtils.defineLazyModuleGetters(this, {
   appIdleManager: "resource:///modules/AppIdleManager.jsm",
   Gloda: "resource:///modules/gloda/GlodaPublic.jsm",
   MailE10SUtils: "resource:///modules/MailE10SUtils.jsm",
   MailUtils: "resource:///modules/MailUtils.jsm",
--- a/mail/base/content/messenger-customization.js
+++ b/mail/base/content/messenger-customization.js
@@ -1,14 +1,13 @@
 /**
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AddonManager } = ChromeUtils.import(
   "resource://gre/modules/AddonManager.jsm"
 );
 
 var AutoHideMenubar = {
   get _node() {
     delete this._node;
     return (this._node =
--- a/mail/base/content/msgHdrView.js
+++ b/mail/base/content/msgHdrView.js
@@ -12,17 +12,16 @@
 /* import-globals-from mailCore.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from messageDisplay.js */
 /* global Enigmail, showMessageReadSecurityInfo, onMessageSecurityPopupShown, onMessageSecurityPopupHidden */
 
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { DisplayNameUtils } = ChromeUtils.import(
   "resource:///modules/DisplayNameUtils.jsm"
 );
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 var { GlodaUtils } = ChromeUtils.import(
   "resource:///modules/gloda/GlodaUtils.jsm"
--- a/mail/base/content/msgMail3PaneWindow.js
+++ b/mail/base/content/msgMail3PaneWindow.js
@@ -24,17 +24,16 @@
 /* import-globals-from spacesToolbar.js */
 
 /* globals loadCalendarComponent */
 
 ChromeUtils.import("resource:///modules/activity/activityModules.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   BondOpenPGP: "chrome://openpgp/content/BondOpenPGP.jsm",
   Color: "resource://gre/modules/Color.jsm",
   CustomizableUI: "resource:///modules/CustomizableUI.jsm",
--- a/mail/base/content/msgViewNavigation.js
+++ b/mail/base/content/msgViewNavigation.js
@@ -5,18 +5,16 @@
 
 /*  This file contains the js functions necessary to implement view navigation within the 3 pane. */
 
 /* import-globals-from commandglue.js */
 /* import-globals-from folderDisplay.js */
 /* import-globals-from mailWindow.js */
 /* import-globals-from messageDisplay.js */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 ChromeUtils.defineModuleGetter(
   this,
   "FolderUtils",
   "resource:///modules/FolderUtils.jsm"
 );
 
 function GetSubFoldersInFolderPaneOrder(folder) {
   function compareFolderSortKey(folder1, folder2) {
--- a/mail/base/content/multimessageview.js
+++ b/mail/base/content/multimessageview.js
@@ -17,17 +17,16 @@ var { DisplayNameUtils } = ChromeUtils.i
 );
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 var { PluralStringFormatter, makeFriendlyDateAgo } = ChromeUtils.import(
   "resource:///modules/TemplateUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   MessageArchiver: "resource:///modules/MessageArchiver.jsm",
   TagUtils: "resource:///modules/TagUtils.jsm",
 });
 
 var gMessenger = Cc["@mozilla.org/messenger;1"].createInstance(Ci.nsIMessenger);
 
--- a/mail/base/content/newTagDialog.js
+++ b/mail/base/content/newTagDialog.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { MailServices } = ChromeUtils.import(
   "resource:///modules/MailServices.jsm"
 );
 
 var dialog;
 
 /**
  * Pass in keyToEdit as a window argument to turn this dialog into an edit
--- a/mail/base/content/nsContextMenu.js
+++ b/mail/base/content/nsContextMenu.js
@@ -11,17 +11,16 @@
 /* global EnigmailURIs: false, gEncryptedURIService: true */
 
 var { InlineSpellChecker, SpellCheckHelper } = ChromeUtils.import(
   "resource://gre/modules/InlineSpellChecker.jsm"
 );
 var { PlacesUtils } = ChromeUtils.import(
   "resource://gre/modules/PlacesUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 ChromeUtils.defineModuleGetter(
   this,
--- a/mail/base/content/printUtils.js
+++ b/mail/base/content/printUtils.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 XPCOMUtils.defineLazyModuleGetters(this, {
   MailE10SUtils: "resource:///modules/MailE10SUtils.jsm",
   SubDialogManager: "resource://gre/modules/SubDialog.jsm",
 });
--- a/mail/base/content/profileDowngrade.js
+++ b/mail/base/content/profileDowngrade.js
@@ -2,17 +2,16 @@
  * 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/. */
 
 let gParams;
 
 const { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
-const { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 function init() {
   /*
    * The C++ code passes a dialog param block using its integers as in and out
    * arguments for this UI. The following are the uses of the integers:
    *
    *  0: A set of flags from nsIToolkitProfileService.downgradeUIFlags.
    *  1: A return argument, one of nsIToolkitProfileService.downgradeUIChoice.
--- a/mail/base/content/sanitize.js
+++ b/mail/base/content/sanitize.js
@@ -1,13 +1,12 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { PlacesUtils } = ChromeUtils.import(
   "resource://gre/modules/PlacesUtils.jsm"
 );
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 
 function Sanitizer() {}
--- a/mail/base/content/spacesToolbar.js
+++ b/mail/base/content/spacesToolbar.js
@@ -1,16 +1,14 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 "use strict";
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 /* import-globals-from msgMail3PaneWindow.js */
 /* import-globals-from mailCore.js */
 
 /**
  * Special vertical toolbar to organize all the buttons opening a tab.
  */
 var gSpacesToolbar = {
   SUPPORTED_BADGE_STYLES: ["--spaces-button-badge-bg-color"],
--- a/mail/base/content/specialTabs.js
+++ b/mail/base/content/specialTabs.js
@@ -5,17 +5,16 @@
 /* global MozElements, openOptionsDialog */
 
 /* import-globals-from mailWindow.js */
 /* import-globals-from utilityOverlay.js */
 
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { AddonManager } = ChromeUtils.import(
   "resource://gre/modules/AddonManager.jsm"
 );
 var { ExtensionParent } = ChromeUtils.import(
   "resource://gre/modules/ExtensionParent.jsm"
 );
 
 function tabProgressListener(aTab, aStartsBlank) {
--- a/mail/base/content/systemIntegrationDialog.js
+++ b/mail/base/content/systemIntegrationDialog.js
@@ -1,16 +1,15 @@
 /* -*- Mode: Javascript; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
  * This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 // This dialog can only be opened if we have a shell service.
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { SearchIntegration } = ChromeUtils.import(
   "resource:///modules/SearchIntegration.jsm"
 );
 
 var gSystemIntegrationDialog = {
   _shellSvc: Cc["@mozilla.org/mail/shell-service;1"].getService(
     Ci.nsIShellService
   ),
--- a/mail/base/content/tabmail.js
+++ b/mail/base/content/tabmail.js
@@ -9,20 +9,16 @@
 /* import-globals-from commandglue.js */
 /* import-globals-from mailCore.js */
 /* import-globals-from mailWindow.js */
 
 var { UIFontSize } = ChromeUtils.import("resource:///modules/UIFontSize.jsm");
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
-
   /**
    * The MozTabmailAlltabsMenuPopup widget is used as a menupopup to list all the
    * currently opened tabs.
    *
    * @extends {MozElements.MozMenuPopup}
    * @implements {EventListener}
    */
   class MozTabmailAlltabsMenuPopup extends MozElements.MozMenuPopup {
@@ -1312,17 +1308,20 @@ var { UIFontSize } = ChromeUtils.import(
       }
 
       return window
         .openDialog(
           "chrome://messenger/content/messenger.xhtml",
           "_blank",
           features.join(","),
           null,
-          { action: "restore", tabs: [tab] }
+          {
+            action: "restore",
+            tabs: [tab],
+          }
         )
         .focus();
     }
 
     moveTabTo(aTabIndexNodeOrInfo, aIndex) {
       let [oldIdx, tab, tabNode] = this._getTabContextForTabbyThing(
         aTabIndexNodeOrInfo,
         false
--- a/mail/base/content/troubleshootMode.js
+++ b/mail/base/content/troubleshootMode.js
@@ -1,14 +1,13 @@
 /* -*- Mode: JavaScript; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPIDatabase } = ChromeUtils.import(
   "resource://gre/modules/addons/XPIDatabase.jsm"
 );
 
 function restartApp() {
   Services.startup.quit(
     Services.startup.eForceQuit | Services.startup.eRestart
   );
--- a/mail/base/content/utilityOverlay.js
+++ b/mail/base/content/utilityOverlay.js
@@ -5,17 +5,16 @@
 /* import-globals-from mailWindow.js */
 
 var { AppConstants } = ChromeUtils.import(
   "resource://gre/modules/AppConstants.jsm"
 );
 var { PlacesUtils } = ChromeUtils.import(
   "resource://gre/modules/PlacesUtils.jsm"
 );
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 
 var gShowBiDi = false;
 
 function getBrowserURL() {
   return AppConstants.BROWSER_CHROME_URL;
 }
 
 // update menu items that rely on focus
@@ -271,17 +270,20 @@ function openTab(tabType, tabParams, whe
 
   // Either we explicitly wanted to open in a new window, or we fell through to
   // here because there's no 3pane.
   return window.openDialog(
     "chrome://messenger/content/messenger.xhtml",
     "_blank",
     "chrome,dialog=no,all",
     null,
-    { tabType, tabParams }
+    {
+      tabType,
+      tabParams,
+    }
   );
 }
 
 /**
  * Open the specified URL as a content tab (or window)
  *
  * @param {String} url - The location to open.
  * @param {String} [where="tab"] - 'tab' to open in a new tab or 'window' to
--- a/mail/base/content/viewSource.js
+++ b/mail/base/content/viewSource.js
@@ -1,17 +1,16 @@
 // -*- indent-tabs-mode: nil; js-indent-level: 2 -*-
 
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* globals gViewSourceUtils, internalSave, ZoomManager */
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
 var { XPCOMUtils } = ChromeUtils.import(
   "resource://gre/modules/XPCOMUtils.jsm"
 );
 
 XPCOMUtils.defineLazyScriptGetter(
   this,
   "PrintUtils",
   "chrome://messenger/content/printUtils.js"
--- a/mail/base/content/viewZoomOverlay.js
+++ b/mail/base/content/viewZoomOverlay.js
@@ -6,18 +6,16 @@
 
 /* globals getBrowser */
 
 /** Document Zoom Management Code
  *
  * Forked from M-C since we don't provide a global gBrowser variable.
  **/
 
-var { Services } = ChromeUtils.import("resource://gre/modules/Services.jsm");
-
 var ZoomManager = {
   get MIN() {
     delete this.MIN;
     return (this.MIN = Services.prefs.getIntPref("zoom.minPercent") / 100);
   },
 
   get MAX() {
     delete this.MAX;
--- a/mail/base/content/widgets/foldersummary.js
+++ b/mail/base/content/widgets/foldersummary.js
@@ -6,19 +6,16 @@
 /* global MozElements */
 /* global MozXULElement */
 /* import-globals-from ../../../../mailnews/base/content/newmailalert.js */
 /* import-globals-from ../folderDisplay.js */
 /* import-globals-from ../folderPane.js */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { MailServices } = ChromeUtils.import(
     "resource:///modules/MailServices.jsm"
   );
 
   /**
    * MozFolderSummary displays a listing of NEW mails for the folder in question.
    * For each mail the subject, sender and a message preview can be included.
    * @extends {MozXULElement}
--- a/mail/base/content/widgets/gloda-autocomplete-input.js
+++ b/mail/base/content/widgets/gloda-autocomplete-input.js
@@ -11,19 +11,16 @@
 
 // The autocomplete CE is defined lazily. Create one now to get
 // autocomplete-input defined, allowing us to inherit from it.
 if (!customElements.get("autocomplete-input")) {
   delete document.createXULElement("input", { is: "autocomplete-input" });
 }
 
 customElements.whenDefined("autocomplete-input").then(() => {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { AppConstants } = ChromeUtils.import(
     "resource://gre/modules/AppConstants.jsm"
   );
 
   const LazyModules = {};
 
   ChromeUtils.defineModuleGetter(
     LazyModules,
--- a/mail/base/content/widgets/glodaFacet.js
+++ b/mail/base/content/widgets/glodaFacet.js
@@ -1,19 +1,16 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* global DateFacetVis, FacetContext */
 
 // Wrap in a block to prevent leaking to window scope.
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { MailServices } = ChromeUtils.import(
     "resource:///modules/MailServices.jsm"
   );
   const { TagUtils } = ChromeUtils.import("resource:///modules/TagUtils.jsm");
   const { FacetUtils } = ChromeUtils.import(
     "resource:///modules/gloda/Facet.jsm"
   );
   const { PluralForm } = ChromeUtils.import(
--- a/mail/base/content/widgets/header-fields.js
+++ b/mail/base/content/widgets/header-fields.js
@@ -1,18 +1,15 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 /* global gMessageHeader, gShowCondensedEmailAddresses, openUILink */
 
 {
-  const { Services } = ChromeUtils.import(
-    "resource://gre/modules/Services.jsm"
-  );
   const { DisplayNameUtils } = ChromeUtils.import(
     "resource:///modules/DisplayNameUtils.jsm"
   );
   const { MailServices } = ChromeUtils.import(
     "resource:///modules/MailServices.jsm"
   );
   const { TagUtils } = ChromeUtils.import("resource:///modules/TagUtils.jsm");
 
@@ -607,17 +604,19 @@
           `message-header-${this.dataset.headerName}-field`
         );
       } else {
         // If this simple row is used by an autogenerated custom header,
         // use directly that header value as label.
         document.l10n.setAttributes(