Skip to content

Commit

Permalink
Rollback change to fix icon not switching
Browse files Browse the repository at this point in the history
  • Loading branch information
benmcgarry committed Mar 28, 2024
1 parent 701ea16 commit 36b5fc8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/environment/background/pageAction.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@
import { addListener, sendMessage } from './messaging';

(process.env.BUILD_TARGET === 'firefox' ? chrome.pageAction : chrome.action).onClicked.addListener(tab => {
sendMessage((process.env.BUILD_TARGET === 'firefox' ? 'pageActionClick' : 'actionClick'), undefined, tab.id);
sendMessage('pageActionClick', undefined, tab.id);
});

addListener((process.env.BUILD_TARGET === 'firefox' ? 'pageAction' : 'action'), ({ operation, state }, { tab }) => {
addListener('pageAction', ({ operation, state }, { tab }) => {
switch (operation) {
case 'show':
(process.env.BUILD_TARGET === 'firefox' ? chrome.pageAction : chrome.action).show(tab.id);
Expand Down

0 comments on commit 36b5fc8

Please sign in to comment.