mirror of
https://github.com/mdn/webextensions-examples.git
synced 2026-04-16 06:18:35 +02:00
Make menus calls synch (#345)
This commit is contained in:
@@ -16,11 +16,11 @@ browser.menus.onClicked.addListener((info, tab) => {
|
||||
}
|
||||
});
|
||||
|
||||
async function updateMenuItem(linkHostname) {
|
||||
await browser.menus.update(openLabelledId, {
|
||||
function updateMenuItem(linkHostname) {
|
||||
browser.menus.update(openLabelledId, {
|
||||
title: `Open (${linkHostname})`
|
||||
});
|
||||
await browser.menus.refresh();
|
||||
browser.menus.refresh();
|
||||
}
|
||||
|
||||
browser.menus.onShown.addListener(info => {
|
||||
|
||||
Reference in New Issue
Block a user