From 5ee010bbf84b9988672b334fafd73c3ad8ed288b Mon Sep 17 00:00:00 2001 From: Stefan Sterz Date: Thu, 25 Feb 2016 13:00:00 +0100 Subject: [PATCH] add debug toggle to config --- nodejs/config.js.example | 2 ++ nodejs/routes/index.js | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/nodejs/config.js.example b/nodejs/config.js.example index ad222f0..bb4842c 100644 --- a/nodejs/config.js.example +++ b/nodejs/config.js.example @@ -7,4 +7,6 @@ config.mysql_database = 'autohome'; config.crypto_secret = 'crypto secret key'; +config.debug = false; + module.exports = config; \ No newline at end of file diff --git a/nodejs/routes/index.js b/nodejs/routes/index.js index 8b9ef17..7b9e8a6 100644 --- a/nodejs/routes/index.js +++ b/nodejs/routes/index.js @@ -12,7 +12,7 @@ var rc_db = new models.RCDB(); var users = new models.Users(); // Arduino communications -var arduino = new arcom.Arduino(true); +var arduino = new arcom.Arduino(config.debug); var rc = new arcom.RC(arduino); // Get arduino ready