GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

Commit 6788592d authored by Arlo Breault's avatar Arlo Breault
Browse files

Require semis

Trac: 34140
parent 0c2ab258
......@@ -8,6 +8,7 @@
"indent": ["error", 2, {
"SwitchCase": 1,
"MemberExpression": 0
}]
}],
"semi": "error"
}
}
......@@ -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));
});
}
......
......@@ -213,6 +213,6 @@ var debug, snowflake, config, broker, ui, log, dbg, init, update, silenceNotific
});
init();
});
}
};
}());
......@@ -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);
})
});
}
......@@ -45,7 +45,7 @@ class Snowflake {
beginWebRTC() {
this.pollBroker();
return this.pollTimeout = setTimeout((() => {
return this.beginWebRTC()
return this.beginWebRTC();
}), this.pollInterval);
}
......
......@@ -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) => {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment