Skip to content

Commit

Permalink
don't listen to broadcast in bg
Browse files Browse the repository at this point in the history
  • Loading branch information
tophf committed Feb 12, 2025
1 parent 93deaaa commit aa8d134
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/msg.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ if (__.ENTRY) {
if (fnOff) port.onDisconnect.addListener(fnOff);
});
}
{
if (!__.IS_BG) {
const S = chrome.storage;
(S.session || S.local.onChanged && S.local || S).onChanged.addListener(onStorage);
(S.session || !__.MV3 && (S.local.onChanged ? S.local : S)).onChanged.addListener(onStorage);
}

export function _execute(data, sender, multi) {
Expand Down

0 comments on commit aa8d134

Please sign in to comment.