Skip to content

Commit

Permalink
fix(paused): correct managed option resolution (#2151)
Browse files Browse the repository at this point in the history
  • Loading branch information
smalluban authored Dec 16, 2024
1 parent 3dcab4d commit 75f9611
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/background/paused.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ OptionsObserver.addListener('paused', async (paused, prevPaused) => {
(prevPaused ||
// Managed mode can update the rules at any time - so we need to update
// the rules even if the paused state hasn't changed
(__PLATFORM__ === 'chromium' && (await store.resolve(Options).managed)))
(__PLATFORM__ === 'chromium' && (await store.resolve(Options)).managed))
) {
const removeRuleIds = (await chrome.declarativeNetRequest.getDynamicRules())
.filter(({ id }) => id <= 3)
Expand Down Expand Up @@ -132,12 +132,12 @@ OptionsObserver.addListener('paused', async (paused, prevPaused) => {
],
removeRuleIds,
});
console.log('[dnr] pause rules updated');
console.log('[dnr] Pause rules updated');
} else if (removeRuleIds.length) {
await chrome.declarativeNetRequest.updateDynamicRules({
removeRuleIds,
});
console.log('[dnr] pause rules updated');
console.log('[dnr] Pause rules cleared');
}
}
});
Expand Down

0 comments on commit 75f9611

Please sign in to comment.