Skip to content

Commit 4678a70

Browse files
committed
Condensed iconPaths init in sync.fade() ↞ [auto-sync from https://github.com/KudoAI/chatgpt.js-chrome-starter]
1 parent 3aeed9d commit 4678a70

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

starters/chrome/extension/popup/controller.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,8 @@
2626

2727
// Update toolbar icon
2828
const iconDimensions = [16, 32, 64, 128], iconPaths = {}
29-
iconDimensions.forEach(dimension => {
30-
iconPaths[dimension] = '../icons/'
31-
+ (config.extensionDisabled ? 'faded/' : '')
32-
+ 'icon' + dimension + '.png'
33-
})
29+
iconDimensions.forEach(dimension => iconPaths[dimension] = `../icons/${
30+
config.extensionDisabled ? 'faded/' : '' }icon${dimension}.png` )
3431
chrome.action.setIcon({ path: iconPaths })
3532

3633
// Update menu contents

0 commit comments

Comments
 (0)