diff --git a/src/js/remote.js b/src/js/remote.js index 0ca104cf10..58c567b7ca 100644 --- a/src/js/remote.js +++ b/src/js/remote.js @@ -189,6 +189,7 @@ var Remote = function (opts, trace) { this.trusted = opts.trusted; this.websocket_ip = opts.websocket_ip; this.websocket_port = opts.websocket_port; + this.local_sequence = opts.local_sequence; this.id = 0; this.trace = opts.trace || trace; this._ledger_current_index = undefined; @@ -714,12 +715,12 @@ Remote.prototype.submit = function (transaction) { }); } else { - if (!transaction.tx_json.Sequence) { + if (self.local_sequence && !transaction.tx_json.Sequence) { transaction.tx_json.Sequence = this.account_seq(transaction.tx_json.Account, 'ADVANCE'); // console.log("Sequence: %s", transaction.tx_json.Sequence); } - if (!transaction.tx_json.Sequence) { + if (self.local_sequence && !transaction.tx_json.Sequence) { // Look in the last closed ledger. this.account_seq_cache(transaction.tx_json.Account, false) .on('success_account_seq_cache', function () { diff --git a/test/config-example.js b/test/config-example.js index 0724941867..7bbff3a0d5 100644 --- a/test/config-example.js +++ b/test/config-example.js @@ -21,6 +21,7 @@ exports.servers = { 'rpc_port' : 5005, 'websocket_ip' : "127.0.0.1", 'websocket_port' : 5006, + 'local_sequence' : true, // 'validation_seed' : "shhDFVsmS2GSu5vUyZSPXYfj1r79h", // 'validators' : "n9L8LZZCwsdXzKUN9zoVxs4YznYXZ9hEhsQZY7aVpxtFaSceiyDZ beta" }