Set default maxLedgerVersion to last closed ledger when requesting account_tx

This commit is contained in:
Alan Cohen
2015-09-16 16:45:25 -07:00
parent 93c12af305
commit 90b53002aa

View File

@@ -71,7 +71,7 @@ function getAccountTx(remote, address, options, marker, limit, callback) {
const params = {
account: address,
ledger_index_min: options.minLedgerVersion || -1,
ledger_index_max: options.maxLedgerVersion || -1,
ledger_index_max: options.maxLedgerVersion || remote.getLedgerSequence(),
forward: options.earliestFirst,
binary: options.binary,
limit: utils.clamp(limit, 10, 400),