1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-10-06 09:37:12 +02:00

this fixes #46

This commit is contained in:
gorhill 2014-07-05 12:56:16 -04:00
parent 14f2803239
commit e9301a2728
2 changed files with 7 additions and 6 deletions

View File

@ -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 ) {

View File

@ -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",