From 6ea9933d6042aa72ddb931d6675b650439634b19 Mon Sep 17 00:00:00 2001 From: Senad Uka Date: Sun, 28 Feb 2016 11:19:18 +0100 Subject: [PATCH] performance update --- app/client/log.js | 3 ++- app/client/state.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/client/log.js b/app/client/log.js index e204342..ac9afd6 100644 --- a/app/client/log.js +++ b/app/client/log.js @@ -5,7 +5,8 @@ function sensor_data_collection() { }, { sort: { created_at: -1 - } + }, + limit: 100 }); } diff --git a/app/client/state.js b/app/client/state.js index 17b9edb..412a09a 100644 --- a/app/client/state.js +++ b/app/client/state.js @@ -20,7 +20,8 @@ function sensor_data_collection() { }, { sort: { created_at: -1 - } + }, + limit: 1 }); }