diff --git a/platform/firefox/vapi-background.js b/platform/firefox/vapi-background.js index c14d4c3fd..37344a38e 100644 --- a/platform/firefox/vapi-background.js +++ b/platform/firefox/vapi-background.js @@ -1561,8 +1561,12 @@ vAPI.net.registerListeners = function() { for ( var tab of tabWatcher.tabs() ) { var URI = tab.currentURI; - // Probably isn't the best method to identify the source tab - if ( URI.spec !== details.openerURL ) { + // Probably isn't the best method to identify the source tab. + // Apparently URI can be undefined under some circumstances: I + // believe this may have to do with those very temporary + // browser objects created when opening a new tab, i.e. related + // to https://github.com/gorhill/uBlock/issues/212 + if ( URI && URI.spec !== details.openerURL ) { continue; }