From f6a07b20ba5ad23641c4adc005ce12c8944be674 Mon Sep 17 00:00:00 2001 From: sairajzero Date: Sat, 1 Aug 2020 18:38:10 +0530 Subject: [PATCH] Minor Improvements - generalData now also stores sign and pubKey. - renamed startup fn readSubAdminListFromAPI to readAppConfigFromAPI. - readAppConfigFromAPI also loads settings from the IDB to floGlobals. --- standard_Operations.html | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/standard_Operations.html b/standard_Operations.html index f5a35cf..7e70b37 100644 --- a/standard_Operations.html +++ b/standard_Operations.html @@ -8606,7 +8606,9 @@ Bitcoin.Util = { floGlobals.generalData[filterStr].push({ sender: dataSet[vc].senderID, vectorClock: vc, - message: dataSet[vc].message + message: dataSet[vc].message, + sign: dataSet[vc].sign, + pubKey: dataSet[vc].pubKey }) compactIDB.writeData("generalData", floGlobals.generalData[filterStr], filterStr) floGlobals.generalVC[filterStr] = vc @@ -8828,7 +8830,7 @@ Bitcoin.Util = { }) }, - readSubAdminListFromAPI: function () { + readAppConfigFromAPI: function () { return new Promise((resolve, reject) => { compactIDB.readData("lastTx", floGlobals.adminID).then(lastTx => { floBlockchainAPI.readData(floGlobals.adminID, { @@ -8858,7 +8860,10 @@ Bitcoin.Util = { floGlobals.adminID); compactIDB.readAllData("subAdmins").then(result => { floGlobals.subAdmins = Object.keys(result); - resolve("Read subAdmins from blockchain"); + compactIDB.readAllData("settings").then(result => { + floGlobals.settings = result; + resolve("Read app configuration from blockchain"); + }) }) }) }).catch(error => reject(error))