Skip to content

Commit 55adfed

Browse files
semenkodiracdeltas
authored andcommitted
Fix some tiny but annoying jslint errors
Signed-off-by: Nick Semenkovich <semenko@alum.mit.edu>
1 parent 907b8c0 commit 55adfed

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

chromium/background.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ function displayPageAction(tabId) {
2727

2828
if (tabId != -1 && this.activeRulesets.getRulesets(tabId)) {
2929
chrome.tabs.get(tabId, function(tab) {
30-
if(typeof(tab) == "undefined") {
30+
if(typeof(tab) === "undefined") {
3131
log(DBUG, "Not a real tab. Skipping showing pageAction.");
3232
}
3333
else {
@@ -57,10 +57,10 @@ AppliedRulesets.prototype = {
5757
},
5858

5959
getRulesets: function(tabId) {
60-
if (tabId in this.active_tab_rules)
60+
if (tabId in this.active_tab_rules) {
6161
return this.active_tab_rules[tabId];
62-
else
63-
return null;
62+
}
63+
return null;
6464
},
6565

6666
removeTab: function(tabId) {
@@ -86,8 +86,9 @@ function onBeforeRequest(details) {
8686
// Normalise hosts such as "www.example.com."
8787
var tmphost = tmpuri.hostname();
8888
if (tmphost.charAt(tmphost.length - 1) == ".") {
89-
while (tmphost.charAt(tmphost.length - 1) == ".")
89+
while (tmphost.charAt(tmphost.length - 1) == ".") {
9090
tmphost = tmphost.slice(0,-1);
91+
}
9192
tmpuri.hostname(tmphost); // No need to update the hostname unless it's changed.
9293
}
9394

0 commit comments

Comments
 (0)