From 024219f59e7c0ab047201d7e26efa3c461968d6c Mon Sep 17 00:00:00 2001 From: gorhill Date: Wed, 15 Apr 2015 18:45:07 -0400 Subject: [PATCH] update badge only when block count changes --- src/js/tab.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/tab.js b/src/js/tab.js index 65ef280e7..e416bd93b 100644 --- a/src/js/tab.js +++ b/src/js/tab.js @@ -471,9 +471,6 @@ vAPI.tabs.onPopup = function(details) { if ( pageStore ) { pageStore.logRequest(context, result); } - if ( µb.userSettings.showIconBadge ) { - µb.updateBadgeAsync(details.openerTabId); - } // Not blocked if ( µb.isAllowResult(result) ) { @@ -481,6 +478,9 @@ vAPI.tabs.onPopup = function(details) { } // Blocked + if ( µb.userSettings.showIconBadge ) { + µb.updateBadgeAsync(details.openerTabId); + } // It is a popup, block and remove the tab. µb.unbindTabFromPageStats(details.targetTabId);