mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-04 01:59:38 +02:00
Avoid re-assigning asset cache registry at launch
Related issue: - https://github.com/uBlockOrigin/uBlock-issues/issues/1365
This commit is contained in:
parent
c959fd6cd9
commit
ab5ab8575c
@ -477,7 +477,21 @@ const getAssetCacheRegistry = function() {
|
||||
bin instanceof Object &&
|
||||
bin.assetCacheRegistry instanceof Object
|
||||
) {
|
||||
assetCacheRegistry = bin.assetCacheRegistry;
|
||||
if ( Object.keys(assetCacheRegistry).length === 0 ) {
|
||||
assetCacheRegistry = bin.assetCacheRegistry;
|
||||
} else {
|
||||
console.error(
|
||||
'getAssetCacheRegistry(): assetCacheRegistry reassigned!'
|
||||
);
|
||||
if (
|
||||
Object.keys(bin.assetCacheRegistry).sort().join() !==
|
||||
Object.keys(assetCacheRegistry).sort().join()
|
||||
) {
|
||||
console.error(
|
||||
'getAssetCacheRegistry(): assetCacheRegistry changes overwritten!'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
return assetCacheRegistry;
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user