From e9a3a874bc22a25b863cea39c2310f760b113538 Mon Sep 17 00:00:00 2001 From: git-directory-deploy <> Date: Mon, 8 Mar 2021 14:10:42 +0100 Subject: [PATCH] publish: stopped d-4 generated from commit cb8024d51d6c7cebac552f6be3aaf1390b1707fa --- index.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 0930ce8..103d700 100644 --- a/index.js +++ b/index.js @@ -143,6 +143,8 @@ async function start(fields, cozyParameters) { try { // resetting data for demo only // await resetData() + // const baseUrl = fields.eglBaseURL + // const apiAuthKey = fields.eglAPIAuthKey const baseUrl = cozyParameters.secret.eglBaseURL const apiAuthKey = cozyParameters.secret.eglAPIAuthKey log('info', 'Authenticating ...') @@ -344,7 +346,6 @@ function format(response) { type: value.TypeAgregat } } else { - log('info', 'end of data - date is : ' + value.DateReleve) return { load: null, year: parseInt(time.format('YYYY')), @@ -356,7 +357,8 @@ function format(response) { } } }) - return mapData + const res = [...mapData].filter(v => v.load !== null) + return res } // function processYearAggregation(data, doctype) { -- GitLab