[mv3] Removing multiple keys is supported

This commit is contained in:
Raymond Hill 2026-01-10 12:49:17 -05:00
parent c8004c4b02
commit 5e9b662024
No known key found for this signature in database
GPG key ID: F5630CAE62A14316

View file

@ -73,9 +73,7 @@ const normalizeMatches = matches => {
async function resetCSSCache() {
const keys = await sessionKeys();
return Promise.all(
keys.filter(a => a.startsWith('cache.css.')).map(a => sessionRemove(a))
);
return sessionRemove(keys.filter(a => a.startsWith('cache.css.')));
}
/******************************************************************************/
@ -234,10 +232,7 @@ async function registerCosmetic(realm, context) {
{
const keys = await localKeys();
for ( const key of keys ) {
if ( key.startsWith(`css.${realm}.`) === false ) { continue; }
localRemove(key);
}
localRemove(keys.filter(a => a.startsWith(`css.${realm}.`)));
}
const rulesetIds = [];