mirror of https://github.com/gorhill/uBlock.git
this fixes #1102
This commit is contained in:
parent
475ccccf41
commit
b938022d0b
|
@ -271,6 +271,10 @@ var cachedAssetsManager = (function() {
|
||||||
getEntries(onEntries);
|
getEntries(onEntries);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
exports.rmrf = function() {
|
||||||
|
exports.remove(/./);
|
||||||
|
};
|
||||||
|
|
||||||
exports.onRemovedListener = null;
|
exports.onRemovedListener = null;
|
||||||
|
|
||||||
return exports;
|
return exports;
|
||||||
|
@ -468,6 +472,9 @@ var getRepoMetadata = function(callback) {
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
exports.setHomeURL = function(path, homeURL) {
|
exports.setHomeURL = function(path, homeURL) {
|
||||||
|
if ( typeof homeURL !== 'string' || homeURL === '' ) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
homeURLs[path] = homeURL;
|
homeURLs[path] = homeURL;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -1029,6 +1036,12 @@ exports.put = function(path, content, callback) {
|
||||||
|
|
||||||
/******************************************************************************/
|
/******************************************************************************/
|
||||||
|
|
||||||
|
exports.rmrf = function() {
|
||||||
|
cachedAssetsManager.rmrf();
|
||||||
|
};
|
||||||
|
|
||||||
|
/******************************************************************************/
|
||||||
|
|
||||||
exports.metadata = function(callback) {
|
exports.metadata = function(callback) {
|
||||||
var out = {};
|
var out = {};
|
||||||
|
|
||||||
|
|
|
@ -1058,6 +1058,10 @@ var restoreUserData = function(request) {
|
||||||
}, onCountdown);
|
}, onCountdown);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// https://github.com/gorhill/uBlock/issues/1102
|
||||||
|
// Ensure all currently cached assets are flushed from storage AND memory.
|
||||||
|
µb.assets.rmrf();
|
||||||
|
|
||||||
// If we are going to restore all, might as well wipe out clean local
|
// If we are going to restore all, might as well wipe out clean local
|
||||||
// storage
|
// storage
|
||||||
µb.XAL.keyvalRemoveAll(onAllRemoved);
|
µb.XAL.keyvalRemoveAll(onAllRemoved);
|
||||||
|
|
Loading…
Reference in New Issue