diff options
Diffstat (limited to 'src/background/components/background.js')
-rw-r--r-- | src/background/components/background.js | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/src/background/components/background.js b/src/background/components/background.js index 29124a6..c7a79a1 100644 --- a/src/background/components/background.js +++ b/src/background/components/background.js @@ -56,13 +56,12 @@ export default class BackgroundComponent { } } - broadcastSettingsChanged() { - return browser.tabs.query({}).then((tabs) => { - for (let tab of tabs) { - browser.tabs.sendMessage(tab.id, { - type: messages.SETTINGS_CHANGED, - }); - } - }); + async broadcastSettingsChanged() { + let tabs = await browser.tabs.query({}); + for (let tab of tabs) { + browser.tabs.sendMessage(tab.id, { + type: messages.SETTINGS_CHANGED, + }); + } } } |