[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [snowflake-webext/master] Require semis



commit 6788592d492bc61324e48721b56fb671ba8639fb
Author: Arlo Breault <arlolra@xxxxxxxxx>
Date:   Thu May 7 10:31:45 2020 -0400

    Require semis
    
    Trac: 34140
---
 .eslintrc.json  | 3 ++-
 broker.js       | 4 ++--
 init-badge.js   | 2 +-
 make.js         | 8 ++++----
 snowflake.js    | 2 +-
 static/index.js | 8 ++++----
 6 files changed, 14 insertions(+), 13 deletions(-)

diff --git a/.eslintrc.json b/.eslintrc.json
index 406f9e5..a350b29 100644
--- a/.eslintrc.json
+++ b/.eslintrc.json
@@ -8,6 +8,7 @@
         "indent": ["error", 2, {
           "SwitchCase": 1,
           "MemberExpression": 0
-        }]
+        }],
+        "semi": "error"
     }
 }
diff --git a/broker.js b/broker.js
index 42293ae..84f0929 100644
--- a/broker.js
+++ b/broker.js
@@ -18,7 +18,7 @@ class Broker {
     this.getClientOffer = this.getClientOffer.bind(this);
     this._postRequest = this._postRequest.bind(this);
 
-    this.config = config
+    this.config = config;
     this.url = config.brokerUrl;
     this.clients = 0;
     if (0 === this.url.indexOf('localhost', 0)) {
@@ -64,7 +64,7 @@ class Broker {
         }
       };
       this._xhr = xhr; // Used by spec to fake async Broker interaction
-      var data = {"Version": "1.1", "Sid": id, "Type": this.config.proxyType}
+      var data = {"Version": "1.1", "Sid": id, "Type": this.config.proxyType};
       return this._postRequest(xhr, 'proxy', JSON.stringify(data));
     });
   }
diff --git a/init-badge.js b/init-badge.js
index d9660a8..b627806 100644
--- a/init-badge.js
+++ b/init-badge.js
@@ -213,6 +213,6 @@ var debug, snowflake, config, broker, ui, log, dbg, init, update, silenceNotific
       });
       init();
     });
-  }
+  };
 
 }());
diff --git a/make.js b/make.js
index e27871d..00c49b2 100755
--- a/make.js
+++ b/make.js
@@ -49,7 +49,7 @@ var concatJS = function(outDir, init, outFile, pre) {
 };
 
 var copyTranslations = function(outDir) {
-  execSync('git submodule update --init -- translation')
+  execSync('git submodule update --init -- translation');
   execSync(`cp -rf translation/* ${outDir}/_locales/`);
 };
 
@@ -65,7 +65,7 @@ var getDisplayName = function(locale) {
     return '';
   }
   return name;
-}
+};
 
 var availableLangs = function() {
   let out = "const availableLangs = new Set([\n";
@@ -155,7 +155,7 @@ task('node', 'build the node binary', function() {
 });
 
 var updateVersion = function(file, version) {
-  var obj = require(file)
+  var obj = require(file);
   obj.version = version;
   writeFileSync(file, JSON.stringify(obj, null, 2), 'utf8');
 };
@@ -211,5 +211,5 @@ if (tasks.has(cmd)) {
 
   tasks.forEach(function(value, key) {
     console.log(key + ' - ' + value.msg);
-  })
+  });
 }
diff --git a/snowflake.js b/snowflake.js
index 11a7801..be475ec 100644
--- a/snowflake.js
+++ b/snowflake.js
@@ -45,7 +45,7 @@ class Snowflake {
   beginWebRTC() {
     this.pollBroker();
     return this.pollTimeout = setTimeout((() => {
-      return this.beginWebRTC()
+      return this.beginWebRTC();
     }), this.pollInterval);
   }
 
diff --git a/static/index.js b/static/index.js
index 80a3aeb..410fc1d 100644
--- a/static/index.js
+++ b/static/index.js
@@ -37,7 +37,7 @@ var getLang = function() {
     return lang;
   }
   return defaultLang;
-}
+};
 
 var fill = function(n, func) {
   switch(n.nodeType) {
@@ -47,14 +47,14 @@ var fill = function(n, func) {
       if (m) {
         var val = func(m[1]);
         if (val != undefined) {
-          n.innerHTML = val
+          n.innerHTML = val;
         }
       }
       n.childNodes.forEach(c => fill(c, func));
       break;
     }
   }
-}
+};
 
 
 fetch(`./_locales/${getLang()}/messages.json`)
@@ -64,7 +64,7 @@ fetch(`./_locales/${getLang()}/messages.json`)
 })
 .then((json) => {
   var language = document.getElementById('language-switcher');
-  var lang = `${getLang()}`
+  var lang = `${getLang()}`;
   language.innerText = availableLangs[lang].name + ' (' + lang + ')';
   var messages = new Messages(json);
   fill(document.body, (m) => {

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits