Remove lexical declaration from cases
This commit is contained in:
parent
4db94ce6c3
commit
cca2ed6991
1 changed files with 5 additions and 5 deletions
10
EUS.js
10
EUS.js
|
@ -212,6 +212,7 @@ module.exports = {
|
||||||
}
|
}
|
||||||
|
|
||||||
function handleAPI(req, res) {
|
function handleAPI(req, res) {
|
||||||
|
let jsonaa = {}, filesaa = 0, spaceaa = 0;
|
||||||
switch (req.url.split("?")[0]) {
|
switch (req.url.split("?")[0]) {
|
||||||
// Status check to see the onlint status of EUS
|
// Status check to see the onlint status of EUS
|
||||||
// Used by ESL to make sure EUS is online
|
// Used by ESL to make sure EUS is online
|
||||||
|
@ -224,9 +225,9 @@ function handleAPI(req, res) {
|
||||||
s : Values [0,1]
|
s : Values [0,1]
|
||||||
*/
|
*/
|
||||||
case "/api/get-stats":
|
case "/api/get-stats":
|
||||||
const filesaa = req.query["f"],
|
filesaa = req.query["f"];
|
||||||
spaceaa = req.query["s"];
|
spaceaa = req.query["s"];
|
||||||
let jsonaa = {};
|
jsonaa = {};
|
||||||
// If total files is asked for
|
// If total files is asked for
|
||||||
if (filesaa == 1) {
|
if (filesaa == 1) {
|
||||||
let total = 0;
|
let total = 0;
|
||||||
|
@ -281,11 +282,10 @@ function handleAPI(req, res) {
|
||||||
|
|
||||||
// Information API
|
// Information API
|
||||||
case "/api/get-info":
|
case "/api/get-info":
|
||||||
let jsona = {
|
return res.end(JSON.stringify({
|
||||||
version: global.internals.version,
|
version: global.internals.version,
|
||||||
instance: config["server"]["instance_type"]
|
instance: config["server"]["instance_type"]
|
||||||
};
|
}));
|
||||||
return res.end(JSON.stringify(jsona));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue