1 /* This Source Code Form is subject to the terms of the Mozilla Public
2 * License, v. 2.0. If a copy of the MPL was not distributed with this
3 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 ChromeUtils.defineESModuleGetters(lazy, {
8 RemoteSettings: "resource://services-settings/remote-settings.sys.mjs",
11 export var RemoteSettingsTimer = function () {};
12 RemoteSettingsTimer.prototype = {
13 QueryInterface: ChromeUtils.generateQI(["nsITimerCallback"]),
14 classID: Components.ID("{5e756573-234a-49ea-bbe4-59ec7a70657d}"),
15 contractID: "@mozilla.org/services/settings;1",
17 // By default, this timer fires once every 24 hours. See the "services.settings.poll_interval" pref.
19 lazy.RemoteSettings.pollChanges({ trigger: "timer" }).catch(e =>