1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-09-15 15:32:28 +02:00

Skip trying to find effective context for about:srcdoc frames

`about:srcdoc` frames are their own origin, trying to
use the origin of the parent context causes an
exception to be thrown when accessing location.href.
This commit is contained in:
Raymond Hill 2020-11-21 09:51:14 -05:00
parent 4b943cf07f
commit 8d3c4916b0
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -116,7 +116,7 @@ vAPI.contentScript = true;
try {
while (
context !== self.top &&
context.location.protocol === 'about:'
context.location.href.startsWith('about:blank')
) {
context = context.parent;
}