mirror of
https://github.com/gorhill/uBlock.git
synced 2026-03-11 09:04:36 +00:00
[mv3] Removing multiple keys is supported
This commit is contained in:
parent
c8004c4b02
commit
5e9b662024
1 changed files with 2 additions and 7 deletions
|
|
@ -73,9 +73,7 @@ const normalizeMatches = matches => {
|
||||||
|
|
||||||
async function resetCSSCache() {
|
async function resetCSSCache() {
|
||||||
const keys = await sessionKeys();
|
const keys = await sessionKeys();
|
||||||
return Promise.all(
|
return sessionRemove(keys.filter(a => a.startsWith('cache.css.')));
|
||||||
keys.filter(a => a.startsWith('cache.css.')).map(a => sessionRemove(a))
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
@ -234,10 +232,7 @@ async function registerCosmetic(realm, context) {
|
||||||
|
|
||||||
{
|
{
|
||||||
const keys = await localKeys();
|
const keys = await localKeys();
|
||||||
for ( const key of keys ) {
|
localRemove(keys.filter(a => a.startsWith(`css.${realm}.`)));
|
||||||
if ( key.startsWith(`css.${realm}.`) === false ) { continue; }
|
|
||||||
localRemove(key);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const rulesetIds = [];
|
const rulesetIds = [];
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue