aboutsummaryrefslogtreecommitdiffstats
path: root/platform
diff options
context:
space:
mode:
authorgorhill <rhill@raymondhill.net>2015-06-15 15:57:12 -0400
committergorhill <rhill@raymondhill.net>2015-06-15 15:57:12 -0400
commitf29f0a0f098f0b6eaef6978eb9cf16e20ab431de (patch)
treebaa8dbc910d59bd719edfc5f24f5667aab8a57dd /platform
parent13a5495f2872e15d2430708c0a56411caa28c57f (diff)
downloaduBlock-f29f0a0f098f0b6eaef6978eb9cf16e20ab431de.zip
uBlock-f29f0a0f098f0b6eaef6978eb9cf16e20ab431de.tar.gz
uBlock-f29f0a0f098f0b6eaef6978eb9cf16e20ab431de.tar.bz2
code review
Diffstat (limited to 'platform')
-rw-r--r--platform/firefox/vapi-background.js8
1 files changed, 1 insertions, 7 deletions
diff --git a/platform/firefox/vapi-background.js b/platform/firefox/vapi-background.js
index 897dfbe..1ca8b73 100644
--- a/platform/firefox/vapi-background.js
+++ b/platform/firefox/vapi-background.js
@@ -2085,13 +2085,7 @@ vAPI.toolbarButton.updateState = function(win, tabId) {
var icon = this.tabs[tabId];
button.setAttribute('badge', icon && icon.badge || '');
-
- if ( !icon || !icon.img ) {
- button.classList.add('off');
- }
- else {
- button.classList.remove('off');
- }
+ button.classList.toggle('off', !icon || !icon.img);
};
/******************************************************************************/