floDapps v2.3.5
- Added get property trustedIDs to floGlobals ie, floGlobals.trustedIDs will give the list of trustedIDs for the app
This commit is contained in:
parent
8afde73e78
commit
b09c88f0df
10
floDapps.js
10
floDapps.js
@ -1,4 +1,4 @@
|
|||||||
(function (EXPORTS) { //floDapps v2.3.4
|
(function (EXPORTS) { //floDapps v2.3.5
|
||||||
/* General functions for FLO Dapps*/
|
/* General functions for FLO Dapps*/
|
||||||
'use strict';
|
'use strict';
|
||||||
const floDapps = EXPORTS;
|
const floDapps = EXPORTS;
|
||||||
@ -144,11 +144,14 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
var subAdmins, settings
|
var subAdmins, trustedIDs, settings;
|
||||||
Object.defineProperties(floGlobals, {
|
Object.defineProperties(floGlobals, {
|
||||||
subAdmins: {
|
subAdmins: {
|
||||||
get: () => subAdmins
|
get: () => subAdmins
|
||||||
},
|
},
|
||||||
|
trustedIDs: {
|
||||||
|
get: () => trustedIDs
|
||||||
|
},
|
||||||
settings: {
|
settings: {
|
||||||
get: () => settings
|
get: () => settings
|
||||||
},
|
},
|
||||||
@ -317,12 +320,15 @@
|
|||||||
compactIDB.writeData("lastTx", result.totalTxs, `${DEFAULT.application}|${DEFAULT.adminID}`, DEFAULT.root);
|
compactIDB.writeData("lastTx", result.totalTxs, `${DEFAULT.application}|${DEFAULT.adminID}`, DEFAULT.root);
|
||||||
compactIDB.readAllData("subAdmins").then(result => {
|
compactIDB.readAllData("subAdmins").then(result => {
|
||||||
subAdmins = Object.keys(result);
|
subAdmins = Object.keys(result);
|
||||||
|
compactIDB.readAllData("trustedIDs").then(result => {
|
||||||
|
trustedIDs = Object.keys(result);
|
||||||
compactIDB.readAllData("settings").then(result => {
|
compactIDB.readAllData("settings").then(result => {
|
||||||
settings = result;
|
settings = result;
|
||||||
resolve("Read app configuration from blockchain");
|
resolve("Read app configuration from blockchain");
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
})
|
||||||
}).catch(error => reject(error))
|
}).catch(error => reject(error))
|
||||||
})
|
})
|
||||||
});
|
});
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user