diff --git a/js/traffic.js b/js/traffic.js index c3128184c..627f96da4 100644 --- a/js/traffic.js +++ b/js/traffic.js @@ -32,7 +32,7 @@ // Intercept and filter web requests according to white and black lists. var onBeforeRequestHandler = function(details) { - // console.debug('onBeforeRequestHandler()> "%s": %o', details.url, details); + //console.debug('onBeforeRequestHandler()> "%s": %o', details.url, details); // Do not block behind the scene requests. var tabId = details.tabId; @@ -69,7 +69,10 @@ var onBeforeRequestHandler = function(details) { } // Lookup the page store associated with this tab id. - var pageStore = µb.pageStoreFromTabId(tabId) || {}; + var pageStore = µb.pageStoreFromTabId(tabId); + if ( !pageStore ) { + return; + } var reason = false; if ( µb.getNetFilteringSwitch(pageStore.pageHostname) ) { @@ -78,9 +81,7 @@ var onBeforeRequestHandler = function(details) { //quickProfiler.stop(); } // Record what happened. - if ( pageStore.recordRequest ) { - pageStore.recordRequest(requestType, requestURL, reason); - } + pageStore.recordRequest(requestType, requestURL, reason); // Not blocked? if ( reason === false ) { diff --git a/manifest.json b/manifest.json index 1eb6e4d95..d8b54485e 100644 --- a/manifest.json +++ b/manifest.json @@ -2,7 +2,7 @@ "manifest_version": 2, "name": "__MSG_extName__", "short_name": "µBlock", - "version": "0.1.3.3", + "version": "0.1.3.4", "description": "__MSG_extShortDesc__", "icons": { "16": "img/icon_16.png",