From 0cb9f79756f1f0d9176d8c66b483f9930df14369 Mon Sep 17 00:00:00 2001 From: mmcwilliams Date: Thu, 8 Feb 2018 16:16:44 -0500 Subject: [PATCH] Fix typo in reset --- index.js | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/index.js b/index.js index c7c21bb..fe074b2 100644 --- a/index.js +++ b/index.js @@ -247,15 +247,6 @@ function rStatus (req, res, next) { return next() } -function rReset (req, res, next) { - log.info'/reset', {time : +new Date()}) - intval.reset() - setTimeout(() => { - res.send(intval._state) - return next() - }, 10) -} - function rSequence (req, res, next) { let dir = true let exposure = 0 @@ -345,6 +336,15 @@ function rSequence (req, res, next) { } } +function rReset (req, res, next) { + log.info(`/reset`, {time : +new Date()}) + intval.reset() + setTimeout(() => { + res.send(intval._state) + return next() + }, 10) +} + function rUpdate (req, res, next) { log.info(`/update`, { time : +new Date() }) exec('sh ./scripts/update.sh', (err, stdio, stderr) => { @@ -539,6 +539,7 @@ function bSequenceStop (obj, cb) { } function bReset (obj, cb) { + log.info(`reset`, { time : +new Date() }) intval.reset() setTimeout(cb, 10) }