mirror of
https://github.com/gorhill/uBlock.git
synced 2024-10-06 09:37:12 +02:00
#948: this possibly addresses the 1st reported error case
This commit is contained in:
parent
75f8802487
commit
4e9d41a150
@ -2240,7 +2240,10 @@ vAPI.net.registerListeners = function() {
|
|||||||
var browser = e.target;
|
var browser = e.target;
|
||||||
|
|
||||||
// I have seen this happens (at startup time)
|
// I have seen this happens (at startup time)
|
||||||
if ( !browser.currentURI ) {
|
// https://github.com/gorhill/uBlock/issues/948
|
||||||
|
// On older version of Firefox, `browser.webNavigation` can be null,
|
||||||
|
// which would cause currentURI to fail.
|
||||||
|
if ( !browser.webNavigation || !browser.currentURI ) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -738,7 +738,7 @@ FilterContainer.prototype.compileGenericSelector = function(parsed, out) {
|
|||||||
if ( this.isValidSelector(selector) ) {
|
if ( this.isValidSelector(selector) ) {
|
||||||
out.push(
|
out.push(
|
||||||
'c\vlg+\v' +
|
'c\vlg+\v' +
|
||||||
matches[0] + '\v' +
|
matches[0] + '\v' +
|
||||||
selector
|
selector
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -773,7 +773,7 @@ FilterContainer.prototype.compileGenericSelector = function(parsed, out) {
|
|||||||
if ( matches && matches.length === 2 ) {
|
if ( matches && matches.length === 2 ) {
|
||||||
out.push(
|
out.push(
|
||||||
'c\vlg+\v' +
|
'c\vlg+\v' +
|
||||||
matches[1] + '\v' +
|
matches[1] + '\v' +
|
||||||
selector
|
selector
|
||||||
);
|
);
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user