A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/gorhill/uBlock/commit/5e1f4d7906c9e18d9d3c45cc4c265b02f2cfddf1 below:

Invalidate browser's memory cache after using element picker · gorhill/uBlock@5e1f4d7 · GitHub

File tree Expand file treeCollapse file tree 2 files changed

+11

-4

lines changed

Filter options

Expand file treeCollapse file tree 2 files changed

+11

-4

lines changed Original file line number Diff line number Diff line change

@@ -1040,7 +1040,7 @@ const userFilterFromCandidate = function(callback) {

1040 1040 1041 1041

// Cosmetic filter?

1042 1042

if ( v.startsWith('##') ) {

1043 -

callback(hostname + v);

1043 +

callback(hostname + v, true);

1044 1044

return;

1045 1045

}

1046 1046

@@ -1188,16 +1188,17 @@ const onDialogClicked = function(ev) {

1188 1188

// We have to exit from preview mode: this guarantees matching elements

1189 1189

// will be found for the candidate filter.

1190 1190

filterToDOMInterface.preview(false);

1191 -

userFilterFromCandidate(filter => {

1192 -

if ( !filter ) { return; }

1191 +

userFilterFromCandidate((filter = undefined, isCosmetic = false) => {

1192 +

if ( filter === undefined ) { return; }

1193 1193

vAPI.messaging.send(

1194 1194

'elementPicker',

1195 1195

{

1196 1196

what: 'createUserFilter',

1197 1197

autoComment: true,

1198 1198

filters: filter,

1199 1199

origin: window.location.origin,

1200 -

pageDomain: window.location.hostname

1200 +

pageDomain: window.location.hostname,

1201 +

killCache: isCosmetic === false,

1201 1202

}

1202 1203

);

1203 1204

filterToDOMInterface.preview(rawFilterFromTextarea(), true);

Original file line number Diff line number Diff line change

@@ -468,6 +468,12 @@

468 468

this.redirectEngine.freeze();

469 469

this.staticExtFilteringEngine.freeze();

470 470

this.selfieManager.destroy();

471 + 472 +

// https://www.reddit.com/r/uBlockOrigin/comments/cj7g7m/

473 +

// https://www.reddit.com/r/uBlockOrigin/comments/cnq0bi/

474 +

if ( options.killCache ) {

475 +

browser.webRequest.handlerBehaviorChanged();

476 +

}

471 477

};

472 478 473 479

const onLoaded = details => {

You can’t perform that action at this time.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4