Fix regression in looking up scriptlets for entity

Related feedback:
https://www.reddit.com/r/uBlockOrigin/comments/19fihsu/
This commit is contained in:
Raymond Hill 2024-01-26 06:46:21 -05:00
parent 663df76e8a
commit 567508f619
No known key found for this signature in database
GPG key ID: 25E1490B761470C2

View file

@ -349,17 +349,16 @@ export class ScriptletFilteringEngineEx extends ScriptletFilteringEngine {
if ( typeof details.frameId !== 'number' ) { return; }
const hostname = hostnameFromURI(details.url);
const domain = domainFromHostname(hostname);
const request = {
const scriptletDetails = this.retrieve({
tabId: details.tabId,
frameId: details.frameId,
url: details.url,
hostname,
domain: domainFromHostname(hostname),
entity: entityFromDomain(hostname),
};
const scriptletDetails = this.retrieve(request);
domain,
entity: entityFromDomain(domain),
});
if ( scriptletDetails === undefined ) {
contentScriptRegisterer.unregister(hostname);
return;