From f79748bb17f50de794a837098fc5e82d05cc188c Mon Sep 17 00:00:00 2001 From: zeus Date: Fri, 11 Dec 2020 02:16:45 +0200 Subject: [PATCH] add rest --- swarmlab-app/src/run/app.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/swarmlab-app/src/run/app.js b/swarmlab-app/src/run/app.js index e7de5e7..169b767 100755 --- a/swarmlab-app/src/run/app.js +++ b/swarmlab-app/src/run/app.js @@ -393,8 +393,8 @@ cors(corsOptions), (req, res, next) => { //usersession.SOCKET.token = isvalid.token //db.collection('log', onCollection); console.log(JSON.stringify('mongo connected')) - var datestart = DateTime.fromObject(RES.start).toISODate() - var dateend = DateTime.fromObject(RES.end).toISODate() + var datestart = DateTime.fromISO(RES.start).toISODate() + var dateend = DateTime.fromISO(RES.end).toISODate() if(datestart && dateend){ var search_term = { $and: [ { date: { $gt: datestart } }, { date: { $lt: dateend } } ] }; }else if(datestart){