From 37869b163a34784287044ae079aa7a4c6deb2034 Mon Sep 17 00:00:00 2001 From: Bastien Dumont <bdumont@grandlyon.com> Date: Thu, 23 May 2024 16:00:58 +0200 Subject: [PATCH] publish: chore: fix few types errors generated from commit c288effda9d500cf28ccbd61a0f9e0841af47531 --- index.js | 11 +++++++++-- onDeleteAccount.js | 2 +- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/index.js b/index.js index a099b36..3c9d514 100644 --- a/index.js +++ b/index.js @@ -129,6 +129,13 @@ async function start(fields, cozyParameters) { boToken = cozyParameters.secret.boToken } + log('error', 'BO URL') + log('info', boBaseUrl) + + + log('error', 'TOKEN') + log('info', boToken) + // Prevent missing configuration if ( !baseUrl || @@ -540,7 +547,7 @@ async function getDataHalfHour(url, apiAuthKey, userLogin, pointId) { } // If manual execution, retrieve only 1 week otherwise retrieve 4 weeks - const MAX_HISTO = 8 + const MAX_HISTO = manualExecution ? 1 : 4 for (let i = 0; i < MAX_HISTO; i++) { log('info', 'launch process with history') @@ -247931,7 +247938,7 @@ async function saveAccountData(accountId, accountData) { /** * Return account * @param {string} accountId - * @returns {Account} + * @returns {Promise<Account>} */ async function getAccount(accountId) { log('info', `getAccount: ${accountId}`) diff --git a/onDeleteAccount.js b/onDeleteAccount.js index bc1c056..5723ea8 100644 --- a/onDeleteAccount.js +++ b/onDeleteAccount.js @@ -246397,7 +246397,7 @@ async function saveAccountData(accountId, accountData) { /** * Return account * @param {string} accountId - * @returns {Account} + * @returns {Promise<Account>} */ async function getAccount(accountId) { log('info', `getAccount: ${accountId}`) -- GitLab