mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-18 17:02:27 +02:00
Fix typo which could lead to improper filtering context
Related discussion:
- 354ac4f57b (commitcomment-32715209)
This commit is contained in:
parent
875542c964
commit
580c3885df
@ -76,18 +76,21 @@
|
|||||||
} else if ( details.documentUrl !== undefined ) {
|
} else if ( details.documentUrl !== undefined ) {
|
||||||
this.setDocOriginFromURL(details.documentUrl);
|
this.setDocOriginFromURL(details.documentUrl);
|
||||||
} else {
|
} else {
|
||||||
const pageStore = µBlock.pageStoreFromTabId(this.docId);
|
const pageStore = µBlock.pageStoreFromTabId(this.tabId);
|
||||||
const docStore = pageStore && pageStore.frames.get(this.docId);
|
const docStore = pageStore && pageStore.frames.get(this.docId);
|
||||||
if ( docStore ) {
|
if ( docStore ) {
|
||||||
this.docOrigin = undefined;
|
this.docOrigin = undefined;
|
||||||
this.docHostname = docStore.pageHostname;
|
this.docHostname = docStore.pageHostname;
|
||||||
this.docDomain = docStore.pageDomain;
|
this.docDomain = docStore.pageDomain;
|
||||||
|
} else {
|
||||||
|
this.setDocOrigin(this.tabOrigin);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else if ( details.documentUrl !== undefined ) {
|
} else if ( details.documentUrl !== undefined ) {
|
||||||
const normalURL = µBlock.normalizePageURL(0, details.documentUrl);
|
const origin = this.originFromURI(
|
||||||
this.setTabOriginFromURL(normalURL);
|
µBlock.normalizePageURL(0, details.documentUrl)
|
||||||
this.setDocOriginFromURL(normalURL);
|
);
|
||||||
|
this.setDocOrigin(origin).setTabOrigin(origin);
|
||||||
} else if ( this.type === 'sub_frame' ) {
|
} else if ( this.type === 'sub_frame' ) {
|
||||||
const origin = this.originFromURI(this.url);
|
const origin = this.originFromURI(this.url);
|
||||||
this.setDocOrigin(origin).setTabOrigin(origin);
|
this.setDocOrigin(origin).setTabOrigin(origin);
|
||||||
|
Loading…
Reference in New Issue
Block a user