diff --git a/swarmlab-app/src/run/app.js b/swarmlab-app/src/run/app.js index 1df6452..88c508a 100755 --- a/swarmlab-app/src/run/app.js +++ b/swarmlab-app/src/run/app.js @@ -358,7 +358,15 @@ cors(corsOptions), (req, res, next) => { RES.token = req.query["token"] RES.start = req.query["start"] RES.end = req.query["end"] - RES.swarmlabname = req.query["swarmlabname"] + RES.swarmlabname = req.query["swarmlabname"] +/* + * + * validate + * + */ + + + var isvalid = await checkToken(RES.token); if(isvalid.action == 'ok'){ console.log("Authserver ok " + RES.token); @@ -409,8 +417,12 @@ cors(corsOptions), (req, res, next) => { //if( resdata.data.filter(item1 => item1.res25swarmlabname.includes(nameofswarmlab)).length > 0 ){ var regexlog = new RegExp(nameofswarmlab); if( resdata.data.filter(item1 => regexlog.test(item1.res25swarmlabname))){ + console.log('----->>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>--- ' + nameofswarmlab) resdataarray.push(item[i]) RES.found = item[i] + }else{ + console.log('-----<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<--- ' + nameofswarmlab) + } }