Fix directly opening a URL in new tab not triggering content script
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
|
||||
browser.tabs.onUpdated.addListener(async (tabId, changeInfo, tab) => {
|
||||
browser.tabs.onUpdated.addListener((tabId, changeInfo, tab) => {
|
||||
if (changeInfo.status !== 'complete') {
|
||||
browser.pageAction.hide(tabId);
|
||||
await browser.storage.local.remove(`nl_tab_${sender.tab.id}`);
|
||||
browser.storage.local.remove(`nl_tab_${sender.tab.id}`);
|
||||
return;
|
||||
}
|
||||
}, { properties: ["status"] });
|
||||
|
||||
Reference in New Issue
Block a user