floBlockchainAPI v2.5.6a

- minor bug fix: default value for options missing in readAllTxs fn
- removed flosight.duckdns.org from apiURL
This commit is contained in:
sairajzero 2023-05-10 01:46:36 +05:30
parent 46ae8581e4
commit 1390c91907

View File

@ -1,4 +1,4 @@
(function (EXPORTS) { //floBlockchainAPI v2.5.6 (function (EXPORTS) { //floBlockchainAPI v2.5.6a
/* FLO Blockchain Operator to send/receive data from blockchain using API calls*/ /* FLO Blockchain Operator to send/receive data from blockchain using API calls*/
'use strict'; 'use strict';
const floBlockchainAPI = EXPORTS; const floBlockchainAPI = EXPORTS;
@ -6,7 +6,7 @@
const DEFAULT = { const DEFAULT = {
blockchain: floGlobals.blockchain, blockchain: floGlobals.blockchain,
apiURL: { apiURL: {
FLO: ['https://flosight.duckdns.org/', 'https://flosight.ranchimall.net/'], FLO: ['https://flosight.ranchimall.net/'],
FLO_TEST: ['https://flosight-testnet.ranchimall.net/'] FLO_TEST: ['https://flosight-testnet.ranchimall.net/']
}, },
sendAmt: 0.0003, sendAmt: 0.0003,
@ -853,7 +853,7 @@
} }
//Read All Txs of Address (newest first) //Read All Txs of Address (newest first)
const readAllTxs = floBlockchainAPI.readAllTxs = function (addr, options) { const readAllTxs = floBlockchainAPI.readAllTxs = function (addr, options = {}) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
readTxs(addr, options).then(response => { readTxs(addr, options).then(response => {
if (response.incomplete) { if (response.incomplete) {